About     ru | pl
 
AV-School.com
AV-School — New source of IT-knowledge!
All-in-row News Articles
Blogs
Home / Users' blogs / User's blog Marina / Entry comments
Security How to combat annoying ads in Google Chrome?
Rating: +1
20 Aug 10 at 16:06
This is the second article dedicated to the ad blocking setup in browsers. This time we will discuss the web browser developed by Google. At the time of writing the article described browser extensions worked only in develop-version. Now it is possible to use the latest stable build of Google Chrome.

---------------------------------------------------------------------------------------------------
To continue the topic of annoying advertising blocking I'll tell you about popular web browser developed by Google.

You'll need a developer version of Google Chrome to be able to use add-ons. You can download it by the following a link:

http://dev.chromium.org/getting-involved/dev-channel

If you look at browser’s properties you will easy notice that the version begins with the number 4:



This is just what we need.

Now install AdBlock+. You can install it from here (Link).

Once the content-filtering extension is installed, the icon of add-on appears in Chromium:



Everything is ready.

Thus, the purpose is the same - to block two advertisements from Habrahabr website:



So, we begin clicking the AdBlock+ icon and selecting "Block element" option (at the same time we are memorizing keyboard shortcuts for this operation):



Then move the mouse cursor on the area you want to block. Chrome will offer different options and highlight them:



When clicking a selected area the browser highlights it in red and displays a window with a filter which will block the area.



I could not select the entire table of the advertising So I had to click on each part of advertising area. At the same time new filters are added to the existed ones separated by commas. There is no user-friendly filter editor, so I have copied the filter’s string and placed it in a text file. When I carefully examined the text, I noticed that each block contains the same div class = "yandex-direct":



An idea came to my head. I click on the same icon and select “Edit rules”:



And replace its contents with the class = "yandex-direct" in square brackets:



It works! The entire table has been disappeared.

It is not so simple about Flash web banner. It's necessary to click on the banner ad:



The banner is activated as a link when clicking it. By the way, in a previous article I focused on the fact that it is no need to click on the links while inspecting by DOM Inspector. I mentioned the DOM Inspector – because of dev builds of Chromium has a similar tool. This tool is called by right-clicking on the area you need to inspect and selecting the "Inspect Element" option in a context menu:



The page's source code is opened. There we can see the part of source code responsible for this area, it is displayed on the page:



It is possible to expand a hierarchy of source code and move the cursor on the strings inside the main unit. You can see that the area containing the banner is highlighted when moving the cursor on the first string:



As can be seen div class = "banner" is responsible for the banner. Without thinking twice I call a rule editor and add the following:



Click on "OK" and the banner will be disappeared.

Here's the result:



The task is performed successfully.


Dmytro Krasylnikov
"Design and Test Lab", Ltd. 2010
/specially for /

Tag: Google, Chrome, browser, ads

Rating:
+1
| More
Entry comments:
No comments on this entry. Back.

Post a comment

Log in or register to post a comment.
Total number of registered users:  4810 
Online:  12 
Newbe: abwphbkyon

Who's online:
Guests online:  12 
Maximum online (10 May 2011)  80 
Blogs: 19
Posts: 131
Last: 25 Sep 2011
Comments: 5242
Last: Today
 Add new post
 All blogs
Hardware 8
Humor 0
News 2
Personal 48
Security 55
Software 16
Travel 2
 Tags 
linux security perl c++ malware seminar Windows Trojan eclipse programming browser automation virtualbox news IDA KNURE Russia Kharkov sandbox vaccination Virustotal ads c review Qt XML analysis ubuntu hardware interface vkontakte summer laptop battery camp stat rootkit photo social network language Facebook ru attack grub chromium
   Site Map    Feedback    About
Copyright © 2007-2012 «Kaspersky Lab.» : Powered By Danneo RCMSRSS