What's new
  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

thelonelycoder

Part of the Furniture
Welcome
This is Diversion - the Router Ad-Blocker for Asuswrt-Merlin


All install and update infos are on the Diversion website.

May 04 2020
Diversion 4.1.12 is now available
See the Diversion website or this post for the change log.

Diversion is free to use under the GNU General Public License version 3 (GPL-3.0).
If you like Diversion and find it useful, you can help it's further development with a donation.
Thank you!

Diversion is interactive. To start the Diversion UI after installation, use
Code:
diversion
For quick operation options without starting the UI, use
Code:
diversion help
to make yourself familiar with the available options.

4jsJ1XW.png


For a more convenient limited Diversion interaction, there is also an iOS Shortcut for the iOS-only Shortcuts app:

aGtVxdB.png
 
Last edited:
Reserved post
 
All I can say is thank you sir! You are awesome. Donations on the way!!!
 
Yay new software! Looking good so far - need to merge back some of my jffs scripts though (it did warn me :) )

EDIT: example, it wiped the services-start file completely! All restored now, now to push some adblocking test goodness
 
Last edited:
Looking good so far - need to merge back some of my jffs scripts though (it did warn me :) )
It merges the commonly used scripts around here. Those that amtm supports.
For all the funky other stuff that some people paste into the jffs/scripts directory I have no patience to merge when coming from AB-Solution 3.11.x.
Diversion 4.0 can handle it though...
 
It merges the commonly used scripts around here. Those that amtm supports.
For all the funky other stuff that some people paste into the jffs/scripts directory I have no patience to merge when coming from AB-Solution 3.11.x.
Diversion 4.0 can handle it though...
Makes sense. Installer backed it up to entware usb so all good, I run my own strict backups/changelogs too since I have to dabble :)

If I need to make changes, does Diversion check for edits like AB-S and re-apply? i.e. anything I should specifically not do to cause conflicts?

Thanks for the new release :)
 
If I need to make changes, does Diversion check for edits like AB-S and re-apply? i.e. anything I should specifically not do to cause conflicts?
Diversion uses one-liners to hook itself into the start scripts, for example /jffs/scripts/post-mount:
Code:
. /jffs/scripts/post-mount.div # Added by Diversion
This sources the new /jffs/scripts/post-mount.div that starts Entware, no matter whether that device has a label or changes its name for some reason.

If something goes haywire, just run d and Re-Install (does this from local files) or Update Diversion (fetches all new files from remote).
Both ways fix it as all used files are locally stored on your router.

The Diversion files are at /opt/share/diversion, while the dnsmasq log files are at /opt/var/log
 
Diversion uses one-liners to hook itself into the start scripts, for example /jffs/scripts/post-mount:
Code:
. /jffs/scripts/post-mount.div # Added by Diversion
This sources the new /jffs/scripts/post-mount.div that starts Entware, no matter whether that device has a label or changes its name for some reason.

If something goes haywire, just run d and Re-Install (does this from local files) or Update Diversion (fetches all new files from remote).
Both ways fix it as all used files are locally stored on your router.

The Diversion files are at /opt/share/diversion, while the dnsmasq log files are at /opt/var/log
Cheers!
 
Sorry about the minimal Diversion website. For now this old-old AB-Solution website snapshot will have to do.
You all have what you wanted. And I'm glad Diversion is out.
 
I like the Merriam Webster No. 2 definition of diversion best:
Definition of diversion
: something that diverts or amuses : pastime
Hiking is one of her favorite diversions.

a welcome diversion from the pressures of the job
 
Thanks @thelonelycoder for the update.

Unfortunately, the update did not work for me. I have been using a test version of pixelserv-tls v2.1.3-test.4 for a while. It seems while upgrading 3.11.2, the Diversion installer fails to install pixelserv-tls. The error it shows is:

Code:
  i  Checking white and blacklists
  ✔  Whitelist
  ✔  Blacklist
  ✔  Wildcard blacklist created

  i  Probing for pixelserv-tls
  i  Installing pixelserv-tls

Downloading http://bin.entware.net/armv7sf-k2.6/Packages.gz
Updated list of available packages in /opt/var/opkg-lists/entware
Collected errors:
 * opkg_download_pkg: Package pixelserv-tls is not available from any configured src.
 * opkg_install_pkg: Failed to download pixelserv-tls. Perhaps you need to run 'opkg update'?
 * opkg_install_cmd: Cannot install package pixelserv-tls.
Installing pixelserv-tls (V35.HZ12.Kk-1) to root...
    ____  _                    _
   |  _ \(_)_   _____ _ __ ___(_) ___  _ __
   | | | | \ \ / / _ \ '__/ __| |/ _ \| '_ \
   | |_| | |\ V /  __/ |  \__ \ | (_) | | | |
   |____/|_| \_/ \___|_|  |___/_|\___/|_| |_|
 
 This is Diversion 4.0      coded by thelonelycoder
----------------------------------------------------

 Welcome to Diversion - the Router Adblocker!

 Diversion is not installed on this router...
____________________________________________________

 [ Error ] pixelserv-tls install failed.

 Install it now? [1=Yes e=Exit] 1

I tried running the installer again, now it starts the process and does not recognize the earlier Ab-Solution. I guess because during the first attempt, all files were wiped out.
 
Unfortunately, the update did not work for me. I have been using a test version of pixelserv-tls v2.1.3-test.4 for a while. It seems while upgrading 3.11.2, the Diversion installer fails to install pixelserv-tls. The error it shows is:
There was no need to re-Install since you used a very recent version.
Did you port or install new when given the option?
 
There was no need to re-Install since you used a very recent version.
Did you port or install new when given the option?

I did port. The full stack trace:

Code:
admin@RT-AC68U-DF28:/tmp/home/root# /usr/sbin/curl -Os https://diversion.ch/install && sh install
    ____  _                    _
   |  _ \(_)_   _____ _ __ ___(_) ___  _ __
   | | | | \ \ / / _ \ '__/ __| |/ _ \| '_ \
   | |_| | |\ V /  __/ |  \__ \ | (_) | | | |
   |____/|_| \_/ \___|_|  |___/_|\___/|_| |_|
 
 This is Diversion 4.0      coded by thelonelycoder
----------------------------------------------------

 Welcome to Diversion - the Router Adblocker!

 Diversion is not installed on this router...
____________________________________________________

 Install it now? [1=Yes e=Exit] 1

 [ i ] Getting latest installer file
 [ ✔ ] install.div         integrated

 [ i ] Checking router
 [ ✔ ] Asuswrt-Merlin
 [ ✔ ] dos2unix
 [ ✔ ] Netstat
 [ ✔ ] Compatible device(s)
 [ ✔ ] Internet
 [ i ] Router check complete
____________________________________________________

  !  AB-Solution 3.11.2 installation found
     at /tmp/mnt/pdas001/adblocking

 1. Port to Diversion 4.0 (highly recommended)
    Keep AB-Solution 3.11.2 settings
 2. Install Diversion 4.0
    Discard AB-Solution 3.11.2 settings

 Enter your selection [1=Port 2=New] 1

  i  Porting AB-Solution 3.11.2 to Diversion 4.0 Standard

  i  Probing for Entware
  ✔  Entware is already installed

  ✔  Diversion directory structure created
     at  /opt/share/diversion

  i  Stopping AB-Solution 3.11.2
  ✔  Old cron jobs deleted

 Checking pixelserv-tls (AB-Solution)...              alive.
 Shutting down pixelserv-tls...              done.

  ✔  pixelserv-tls stopped
  ✔  Old start scripts cleaned
  i  AB-Solution 3.11.2 stopped

  i  Porting AB-Solution 3.11.2 files and settings
  ✔  White and blacklist ported
  ✔  Shared whitelist ported
  ✔  Blocking file ported
  ✔  Email settings ported
  ✔  Pixelserv switches file ported
  ✔  Client names backup file ported
  ✔  Stats file(s) ported
  ✔  shooter40sw hosts list ported
  ✔  Blocking list settings ported
  ✔  Ad-blocking stats ported
  ✔  Dnsmasq log files ported
  ✔  Communication settings ported
  i  Porting of AB-Solution 3.11.2 complete

  i  Installing Diversion 4.0 Standard

  i  Getting Diversion Standard files from
     https://diversion.ch/diversion/4.0
  ✔  backup.div          integrated
  ✔  functions.div       integrated
  ✔  install.div         integrated
  ✔  post-conf.div       integrated
  ✔  post-mount.div      integrated
  ✔  rc.func.div         integrated
  ✔  rotate-logs.div     integrated
  ✔  stats.div           integrated
  ✔  S80pixelserv-tls    integrated
  ✔  theme.div           integrated
  ✔  update.div          integrated
  ✔  update-bf.div       integrated
  ✔  update-notification integrated
  ✔  write-config.div    integrated

  i  Checking white and blacklists
  ✔  Whitelist
  ✔  Blacklist
  ✔  Wildcard blacklist created

  i  Probing for pixelserv-tls
  i  Installing pixelserv-tls

Downloading http://bin.entware.net/armv7sf-k2.6/Packages.gz
Updated list of available packages in /opt/var/opkg-lists/entware
Collected errors:
 * opkg_download_pkg: Package pixelserv-tls is not available from any configured src.
 * opkg_install_pkg: Failed to download pixelserv-tls. Perhaps you need to run 'opkg update'?
 * opkg_install_cmd: Cannot install package pixelserv-tls.
Installing pixelserv-tls (V35.HZ12.Kk-1) to root...
    ____  _                    _
   |  _ \(_)_   _____ _ __ ___(_) ___  _ __
   | | | | \ \ / / _ \ '__/ __| |/ _ \| '_ \
   | |_| | |\ V /  __/ |  \__ \ | (_) | | | |
   |____/|_| \_/ \___|_|  |___/_|\___/|_| |_|
 
 This is Diversion 4.0      coded by thelonelycoder
----------------------------------------------------

 Welcome to Diversion - the Router Adblocker!

 Diversion is not installed on this router...
____________________________________________________

 [ Error ] pixelserv-tls install failed.
 
There has been a lot going on within pixelserv-tls. As per @kvic 's suggestion a few people have been doing a lot of tinkering to optimize the test versions. I guess it's best not to tinker with pixelser-tls if a test version is running.
 
Whats your output of:
Code:
opkg list-installed | grep pixelserv-tls

I get nothing,

Code:
admin@RT-AC68U-DF28:/tmp/home/root# opkg list-installed | grep pixelserv-tls
admin@RT-AC68U-DF28:/tmp/home/root#
 
There has been a lot going on within pixelserv-tls. As per @kvic 's suggestion a few people have been doing a lot of tinkering to optimize the test versions. I guess it's best not to tinker with pixelser-tls if a test version is running.
If you have the beta version installed through amtm or @kvic installer then it should have worked.
I tested that extensively on my ARM and MIPS routers.
 

Latest threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top