Prevent users to access specific YouTube Channel like 'T-Series'.
Note: Blocking of Specific YouTube channel and allowing all the other YouTube videos is a hypothetical scenario. YouTube website is not designed for such hypothetical situation. However, this how-to will demonstrate to block a specific YouTube Channel and one of its playlist videos.
Prerequisites
You need the YouTube Channel-ID and List-ID. You have to extract Channel-ID and List-ID from YouTube URL before creating rules in SafeSquid.
Policy Creation
We can achieve the above by following steps –
1. Open the YouTube channel you want to block. Here T-Series channel is taken as an example.
Here you will get Channel-ID from the referrer URL. Channel-ID is the preceding portion of the URL after 'channel/' part. Save this part on notepad for reference.
Channel-ID: UCq-Fj5jknLsUf-MWSy4_brA
For List-ID extraction click on PLAY ALL link on the page as shown below.
2. Extract List-ID from any of the subsequent URL.
List-ID is the preceding portion of the URL after '&list=' part. Save this part on notepad for reference.
List-ID: PL9bw4S5ePsEE2KMw53rY40A00t4I-otqy
You will find every Video in the list contain List-ID of the channel.
List-ID: PL9bw4S5ePsEE2KMw53rY40A00t4I-otqy
3. After extracting the Channel-ID and List-ID we have create policies in SafeSquid.
Go to SafeSquid Web-GUI and click on Configure to create Policies.
Create Policy in Request Types Section
4. Click on Custom Settings to open Request Types Section.
6. Make sure the Global of Request Types Section is Enabled to True.
7. Click on Request Types tab to create new policy.
8. Add YouTube Channels in Request Types Field. Create new Request Profile as T-SERIES CHANNEL in Added Request Types Field.
9. You have to add Channel-ID and List-Id in File Field. You have already saved them in notepad for your reference. Refer to Channel-ID extraction and List-Id extraction.
Here for T-Series channel we added (UCq-Fj5jknLsUf-MWSy4_brA|PL9bw4S5ePsEE2KMw53rY40A00t4I-otqy) in File Field.
Save the Policy created.
Create Policy in Access Profiles Section
10. Go to Access Profiles section.
11. Edit the Default Policy already created in SafeSquid named BLOCK YOUTUBE CHANNELS. Select T-SERIES CHANNEL in Request Types Field. Set Action Field as DO_NOT_BYPASS.
12. Save the policy created in Access Restrictions.
Test the YouTube Channel Blocked
13. Now try to open the YouTube Channel of T-Series https://www.youtube.com/channel/UCq-Fj5jknLsUf-MWSy4_brA.
All the YouTube channel of T-series will be blocked and Access block Template will be shown.
If you try to open any of the subsequent YouTube videos of T-Series Channel like https://www.youtube.com/watch?v=IgKdXLfxgQQ&list=PL9bw4S5ePsEE2KMw53rY40A00t4I-otqy.
It will be blocked and Access block Template will be shown.
Note:
This configuration will work only for videos sourced from the channel page and not from the feeds links or YouTube Videos embedded in website.
To block every video of any specific YouTube Channel you have to insert List-ID's (of every playlist in that channel) and file part (of each individual unlisted videos) of URL in the File field of Request Types Section.