Adblock Plugin

Want to share your OpenWrt / Gargoyle knowledge? Implemented a new feature? Let us know here.

Moderator: Moderators

ple0max
Posts: 8
Joined: Fri Dec 18, 2015 1:33 am

Re: Adblock Plugin

Post by ple0max »

Lantis wrote:No idea, that is an unrelated issue. The two systems don't touch each other so i don't know what would cause that.

I just tried it and i can do it just fine.
Thanks. I will just reset everything to see what causes this. :)

Ziggy
Posts: 7
Joined: Thu Feb 11, 2016 10:28 pm

Re: Adblock Plugin

Post by Ziggy »

Lantis wrote:Looks like it isn't working because you're using the TOR plugin.
Is this correct?

Due to the nature of TOR there is currently no way for them to work together (that i know of). I simply made it so that installing this plugin wouldn't break TOR.
Thank you for your reply.
That's strange, I don't have the TOR plugin, in fact I don't even have enough disk space to install it(TOR Anonymizer).
I decided to reset to default configuration and install only the DNS Adblock in the plugins tab, but it still thinks I have TOR enabled for some reason. The only other plugin installed besides the EN language one is the pre-installed Open VPN plugin.
Any other ideas?

Lantis
Moderator
Posts: 6756
Joined: Mon Jan 05, 2015 5:33 am
Location: Australia

Re: Adblock Plugin

Post by Lantis »

uci get tor.global.enabled

Can you tell me the output of that please?

If it comes up as 1, set it to 0.

I don't know why it would if you don't have it installed though.
If it comes up as 0, then you've discovered a strange bug and I'll have to figure it out.
http://lantisproject.com/downloads/gargoyle_ispyisail.php for the latest releases
Please be respectful when posting. I do this in my free time on a volunteer basis.

Ziggy
Posts: 7
Joined: Thu Feb 11, 2016 10:28 pm

Re: Adblock Plugin

Post by Ziggy »

Lantis wrote:uci get tor.global.enabled

Can you tell me the output of that please?

If it comes up as 1, set it to 0.

I don't know why it would if you don't have it installed though.
If it comes up as 0, then you've discovered a strange bug and I'll have to figure it out.
This is what I get:
root@Gargoyle:~# uci get tor.global.enabled
uci: Entry not found

Lantis
Moderator
Posts: 6756
Joined: Mon Jan 05, 2015 5:33 am
Location: Australia

Re: Adblock Plugin

Post by Lantis »

For now, do:
uci set tor.global.enabled=0
uci commit tor

Then reenable the plugin.
I have a theory that it's taking "Entry not found" as equal to 1...
How frustrating haha. I'll confirm that later and fix it if so.

Thanks for your help
http://lantisproject.com/downloads/gargoyle_ispyisail.php for the latest releases
Please be respectful when posting. I do this in my free time on a volunteer basis.

Ziggy
Posts: 7
Joined: Thu Feb 11, 2016 10:28 pm

Re: Adblock Plugin

Post by Ziggy »

Lantis wrote:For now, do:
uci set tor.global.enabled=0
uci commit tor

Then reenable the plugin.
I have a theory that it's taking "Entry not found" as equal to 1...
How frustrating haha. I'll confirm that later and fix it if so.

Thanks for your help
I don't know if I'm doing it right, but the uci command doesn't seem to work for me:
"root@Gargoyle:~# uci set tor.global.enabled=0
uci: Entry not found"

Am I running this uci command wrong somehow?

No, thank YOU for helping me! :D

Lantis
Moderator
Posts: 6756
Joined: Mon Jan 05, 2015 5:33 am
Location: Australia

Re: Adblock Plugin

Post by Lantis »

Ahh, so if the config file doesn't exist, the "set" command doesn't create it.
Interesting.

Are you comfortable using something like WinSCP to create the file manually?
It will need to be in /etc/config/
The file will be called "tor".
The contents of the file will be:

Code: Select all

config 'global' 'global'
        option enabled        '0'
Not sure if it is important but the permissions should be
rw-r--r--


If you're not comfortable doing this I can write a script that will do it for you but it would have to wait until later. It's Valentine's Day today and I'm otherwise engaged :P
http://lantisproject.com/downloads/gargoyle_ispyisail.php for the latest releases
Please be respectful when posting. I do this in my free time on a volunteer basis.

Ziggy
Posts: 7
Joined: Thu Feb 11, 2016 10:28 pm

Re: Adblock Plugin

Post by Ziggy »

Lantis wrote:Ahh, so if the config file doesn't exist, the "set" command doesn't create it.
Interesting.

Are you comfortable using something like WinSCP to create the file manually?
It will need to be in /etc/config/
The file will be called "tor".
The contents of the file will be:

Code: Select all

config 'global' 'global'
        option enabled        '0'
Not sure if it is important but the permissions should be
rw-r--r--


If you're not comfortable doing this I can write a script that will do it for you but it would have to wait until later. It's Valentine's Day today and I'm otherwise engaged :P
I was able to create the Tor file using putty, and the uci command worked this time:

"root@Gargoyle:/etc# uci get tor.global.enabled
0"
Disabled and enabled Adblock:
Sat Feb 13 16:13:56 2016 user.notice ADBLOCK: Enabling adblock plugin
Sat Feb 13 16:13:56 2016 user.notice ADBLOCK: Removing hosts file from dnsmasq
Sat Feb 13 16:13:56 2016 user.notice ADBLOCK: Removing cron entry
Sat Feb 13 16:13:56 2016 user.notice ADBLOCK: Removing firewall rules
Sat Feb 13 16:13:57 2016 user.notice ADBLOCK: Reverting uHTTPd error page
Sat Feb 13 16:13:57 2016 user.notice ADBLOCK: Adding hosts file to dnsmasq
Sat Feb 13 16:13:57 2016 user.notice ADBLOCK: Adding cron entry
Sat Feb 13 16:13:57 2016 user.notice ADBLOCK: Adding firewall rules
Sat Feb 13 16:13:57 2016 user.notice ADBLOCK: Removing old hosts file
Sat Feb 13 16:13:57 2016 user.notice ADBLOCK: Retrieving ad lists from remote source
Sat Feb 13 16:14:00 2016 user.notice ADBLOCK: Adding entries from black.list
Sat Feb 13 16:14:01 2016 user.notice ADBLOCK: Removing entries from white.list
Sat Feb 13 16:14:05 2016 user.notice ADBLOCK: Restarting firewall
Sat Feb 13 16:14:11 2016 user.notice ADBLOCK: Restarting dnsmasq

Interestingly, I still don't have /etc/block.hosts for some reason.

Thank you so much for your help. Go enjoy your valentines! I can wait until you have time.

ispyisail
Moderator
Posts: 5185
Joined: Mon Apr 06, 2009 3:15 am
Location: New Zealand

Re: Adblock Plugin

Post by ispyisail »

It's Valentine's Day today and I'm otherwise engaged :P
To much time behind a PC I say :)

you will get in trouble like the rest of us :)

Lantis
Moderator
Posts: 6756
Joined: Mon Jan 05, 2015 5:33 am
Location: Australia

Re: Adblock Plugin

Post by Lantis »

@ziggy
I cannot reproduce a scenario where I get no hosts file
http://lantisproject.com/downloads/gargoyle_ispyisail.php for the latest releases
Please be respectful when posting. I do this in my free time on a volunteer basis.

Post Reply