FORUMS
Remove All Ads from XDA

[APP][5.0+] SABS - KNOX front end

509 posts
Thanks Meter: 629
 
Thread Closed Email Thread
logo
SABS - Knox SDK frontend

MOD Edit:- Links Removed

SABS is an open source tool that shows how to use Samsung Knox SDK without root. It lets developers see how various features work and test them. Some of the features are: system-wide domain blocker, package disabler, permission manager, apps force stopper (examples include theme store), system-wide or app-specific port 53 blocker and more.

SABS works on all non-rooted (and knox not triggered) Samsung devices with Android Lollipop 5.0 or higher and Samsung Knox version 2.5 or higher. Testers have confirmed that SABS works without any major issues on these devices: Samsung Galaxy S8, S8+, Note 8, A3 2017, S7, S7 edge, S6, S6 edge, J7 Pro, J7 2016, J5 2016, J5 2015. Some testers have confirmed that SABS works without any major issues but others have reported phone reboots on these devices: S9, S9+.

To develop apps that use Knox SDK or try them out, you need to get the license key. Development license key works for up to 10 devices. To develop an app based on SABS or try it out, you have to also change the package name (id) to get your own 10 development seats. Instructions are below.

As featured in:
  • Lifehacker:
    "Simple Ad-blocker for Samsung (SABS for short) promises to remove all those pesky ads and then some. The app works by tapping into Samsung’s ultra-secure KNOX software. That gives it the ability to disable packages—A.K.A. the terrible bloatware slathered on by your carrier. SABS also includes a system-level permission manager, giving you an extra level of control over what apps can see and do on your phone."

  • XDA Developers:
    "Along with providing an ad blocker service, SABS can also disable system apps that are impossible to disable within the settings application without root. You can also use it to remove permissions from apps that you can’t usually control."

  • Gizmodo:
    "There are many adblockers in the Android App Store. Most eliminate ads or replace them with something that does not bother the eye. Simple Ad-blocker for Samsung (SABS) takes that function a little further and does something very welcome: put control of the applications in our hands."

Also featured in: Android Community, The Gioi Tre, iCrowdNewswire, TuttoAndroid, InfoGlitz, PametniTelefoni, GameOfThrone, AllAboutPhones, AndroidCure, GizBlog and more!

Table of contents
  • Donate
  • Setup
  • External links
  • FAQ (post #2)
  • Changelog (port #3)

Donate
You can donate to LayoutXML on MOD Edit:- Links Removed
. I'm a school student who is about to go to university. Every dollar helps.

Setup
Congratulations, you are now a developer who is interested in developing (or trying out) an app that uses Knox sdk.

MOD Edit:- Links Removed

Following steps 1-i-ii-a takes about 30 minutes. If you follow steps 1-i-ii-b it will take about 2 minutes. Following steps 2-i-ii-a takes about 2 minutes. If you follow steps 2-i-ii-b it will take about 2 minutes.

Even though the method with a computer takes more the first time, the app will be more stable. Not to mention, that this method is completely free. The method with a phone takes less time at first but you need to use paid app and the app will be less stable.

1. Setup for the first time

Every user of SABS needs to receive a license key directly from Samsung.
Follow along this video to make sure you are following the steps correctly. There are several cuts to hide my personal information in the video.
MOD Edit:- Links Removed
MOD Edit:- Links Removed[/LIST]


Step II - Changing the package name
You can choose to change a package name of the app with or without a computer. Before following the steps below, uninstall any KNOX adblocker you already have installed on your phone such as Adhell, Adhell 2 or Disconnect Pro.

a - With a computer
Follow along this video to make sure you are following the steps correctly.
MOD Edit:- Links Removed[/LIST]

b - With your phone
The are multiple ways to change the package name of the app. Following guide focuses on editing the package name with "APK Editor Pro" app. You can also use different apps if such exist.
Follow along this video to make sure you are following the steps correctly.
MOD Edit:- Links Removed

MOD Edit:- Links Removed
B - With your phone


MOD Edit:- Links Removed

XDA:DevDB Information
SABS, App for all devices (see above for details)

Contributors
MOD Edit:- Links Removed

Version Information
Status: Stable
Current Stable Version: 0.0.9
Stable Release Date: 2018-03-14

Created 2018-02-18
Last Updated 2018-03-15
The Following 137 Users Say Thank You to NeedleGames For This Useful Post: [ View ] Gift NeedleGames Ad-Free
 
 
18th February 2018, 05:20 PM |#2  
NeedleGames's Avatar
OP Senior Member
Thanks Meter: 629
 
Donate to Me
More
FAQ
Is using SABS safe?
Yes, SABS is open source, it uses Samsung Knox SDK.

Why do I have to get my own key?
To use Samsung Knox SDK you need to have a license key. You can get development license for free or become a Samsung partner with a registered business and going through vetting.

Ads are not blocked on application X. What do I do?
SABS is simply a frontend for Samsung Knox. Standard package in app is very light to show what can be achieved with Samsung Knox. mmotti's package has more domains and may be used to block more domains. You can add other packages (blocklists) such as adaway if you want to block ads. You can also block domains yourself. You can also ask this question on xda thread (linked below) and learn what packages others are using.

Do I have to be rooted?
No. Not only you don't have to be rooted, SABS only works on devices with knox not tripped.
The Following 26 Users Say Thank You to NeedleGames For This Useful Post: [ View ] Gift NeedleGames Ad-Free
18th February 2018, 05:20 PM |#3  
NeedleGames's Avatar
OP Senior Member
Thanks Meter: 629
 
Donate to Me
More
Changelog
Latest version:
v0.0.9 (2018-03-15)
Code:
* Layout fixes (text no longer overlays or gets cropped in some areas of app)
* Text improvements
* Improved whitelisting domains (you can now simply whitelist the domain instead of finding it in the package)
* Removed 1 empty permission
* Export unique blocked domains from recent screen to a file
* Choose recent activity time from 1 to 7 days
* Refresh recent activity
* Block theme store from being launched - you can now easily use phone themes from XDA or other websites. (works better than simply disabling theme store in package disabler screen)
* "Restore permissions" option in permissions manager screen
* More
Older releases:
v0.0.8 (2018-03-03)
Code:
* Fixed the bug where blocking would not enable/disable or show incorrect value
* Fixed dialog asking for key going under screen on devices with small screens and big fonts
* Added a loading screen for enabling/disabling blocking, adding block lists (subscribing), updating lists
* Integrated mmotti's domain package into SABS now. You can safely enable both (don't forget to remove the old one if you have added it before)
* Made SABS block domains only once if they appear in multiple packages
* Added a number that shows how many unique domains are blocked across the all packages (whitelisted domains are not included)
* You can now also use files inside the subscribe screen
* Provider in subscribe screen is not cut of anymore
* Fixed the black theme on dialog asking for key
* Increased the chances of successfully blocking big domain lists
* Removed obsolete and not working permissions in permission manager
* Added descriptions for all permissions in permission manager
* Changed the versionCode (internal code in SABS) to show number of commits at the release moment
* More
v0.0.7 (2018-02-23)
Code:
* Added an option to choose whether to block port 53 globally or only on Chrome
* Fixed some app icons not showing up in package disabler
* Updated string.xml with clearer wording and improved settings menu names
* Made long press on an app in package disabler open its settings in phone settings
* Added ability to control READ_CLIPBOARD permission
* Sorted permissions in permissions tab alphabetically
* Fixed custom whitelist being ignored
* Added more fixes and improvements to blocking enabling including but not limited to: fix to not block duplicate domains, fix to first block port 53, 
* Added ability to block or whitelist custom wildcards
* Fixed some issues with domain checking
* Changed updater from dialog to snackbar on black theme
* More
v0.0.6 (2018-02-17)
Code:
* Share blocked package list
* Materialized whitelist, blocking, subscribe, permission in apps screens, redesigned recent activity screen
* Improved search in package blocker screen
* Orange selection bug fix
* New settings screen
* Ability to disable start-up warning
* Black theme (amoled)
* Option to block port 53 (may break some functionality)
* Removed 15k url limit. The only limit now is set by Samsung (AFAIK ~20k)
* More responsive UI
* Margins in settings and in package disabler fixed
* Made the delete button and checkbox in subscribe screen work all the time
* Fixed and closed issues 1-6, responded to the majority of feature requests, bug mentions on reddit
* Cleaned up
* More small changes (check out recent commits)
v0.0.5 (2018-02-07)
Code:
* Optimized for changing package id - no more crashes (if renamed as instructed above), correct uninstall, shows package id in the settings, about screen and lets you copy it by clicking.
* Cleared slides shown at the start when first installing.
* Unblocked port 53 as it is used in many places such as Android Wear. You can expect the option to select whether you want it blocked or not in the future
* Prompt to restore administrative privileges if they get removed
v0.0.4 (2018-02-04)
Code:
* Recent activity screen design changes and improvements
* Internal checker that reminds users that the key cannot start with letters "KLM" if their key does
* A warning screen every time a user opens an app that reminds that it is dangerous to edit some things, and so that there wouldn't be any accidental presses while phone is, for example, in the pocket
* Ability to rotate screen, scroll if items are out of screen, support for more screen sizes
* Faster loading for package disabler
* Search icons in search fields
* Import and export disabled package list file name chooser
* List of domains updated
* Fixes for some domains
* Removed billing permission
* Clean-up
v0.0.3 (2018-01-29)
Code:
* Fixed back press button bug where user would be taken unnecessary amount of steps back (not level based)
* Fixed bottom bar showing in some screens where it shouldn't
* Fixed some titles in screens
* Native support for 18:9 aspect ratio - no need to press to expand app
* Design fixes
* Asynchronous loading! No need to wait for certain elements to load because it's done in the background
* Google Duo is now by default in whitelisted apps because of errors in duo
* Fixed bug where system apps were reported as user apps
v0.0.2 (2018-01-02)
Code:
* Auto updater (notifies about new release, loads website to download)
* Licenses in settings > about
* Removed some dependencies (crashlytics, fabric)
* Updated dependencies
* Material design package manager
* Ripple effect
* Fixed grey background bug (background would change to grey when returning to app when permission manager was on)
* Menu in permission manager
* Pull to refresh in package manager
* Animations in settings
* Snackbars when turning on/off domain blocking, enabling/disabling packages in manager
* One fragment renamed in source files
* Clean-up
v0.0.1 (2018-01-01)
Code:
* New project name, readme file, license
* Lint correctness fixes
* Updated build.gradle dependencies
* New bottom bar navigation view (replaced deprecated roughike's BottomBar)
* Materialized - many design fixes, compliance with Material design guidelines (not finished). Including but not limited to: margins, text sizes, colors, styles
* Complete settings menu redesign
* New app icon, button icons and many other images
* Tutorial slides
* About section with links to view source code, send feedback
* Better (but not finished) error fragments and text informing about errors
* Many layouts changed to constraint layouts
* Ability to control extra 308 permissions
* Permissions are now numbered
* Scrollbar on permissions manager fragment
The Following 22 Users Say Thank You to NeedleGames For This Useful Post: [ View ] Gift NeedleGames Ad-Free
18th February 2018, 05:38 PM |#4  
mmotti's Avatar
Senior Member
Thanks Meter: 581
 
More
First!
The Following 3 Users Say Thank You to mmotti For This Useful Post: [ View ] Gift mmotti Ad-Free
18th February 2018, 05:58 PM |#5  
Senior Member
Thanks Meter: 166
 
More
Second!
18th February 2018, 06:09 PM |#6  
Mike B.'s Avatar
Recognized Contributor
/
Thanks Meter: 3,031
 
10
More
Many thanks to @NeedleGames for making this SABS thread.

Perhaps the most important thing to remember about SABS/AdHell and related projects is that they do not block ads! All they do is configure and launch the Knox firewall, including the ability to block user-defined domains. The key to ad blocking is picking the correct domains to block, and that's done primarily by using the appropriate "providers". The standard package covers most situations, but you can also whitelist (allow) domains that would be otherwise blocked, or blacklist (block) domains not already blocked by the default standard package. In addition, you can also prevent all blocking for applications that you select under "Manage blocking in apps". In general, the less you stray from the default, the better. Please try to investigate those options before assuming that SABS "doesn't work".
The Following 10 Users Say Thank You to Mike B. For This Useful Post: [ View ] Gift Mike B. Ad-Free
18th February 2018, 06:38 PM |#7  
NeedleGames's Avatar
OP Senior Member
Thanks Meter: 629
 
Donate to Me
More
Quote:
Originally Posted by Mike B.

Perhaps the most important thing to remember about SABS/AdHell and related projects is that they do not block ads! .

Yeah, I was thinking about the wording but since the app is called SABS I had no choice but to name the thread appropriately.

SABS uses Samsung's KNOX SDK to block domains, disable apps and permissions. It can use the domain blocking to block domains that serve ads but this is not always possible.
The Following 4 Users Say Thank You to NeedleGames For This Useful Post: [ View ] Gift NeedleGames Ad-Free
18th February 2018, 11:35 PM |#8  
jkolner's Avatar
Senior Member
Flag Aalborg
Thanks Meter: 837
 
More
Just switched from AdHell to SABS and everything works perfectly.

This is my custom blocked hostes:

http://getadhell.com/standard-package.txt
https://pgl.yoyo.org/as/serverlist.php
http://core.royalads.net
https://adaway.org/hosts.txt
https://hosts-file.net/ad_servers.txt
https://www.fanboy.co.nz/r/fanboy-ultimate.txt
The Following 12 Users Say Thank You to jkolner For This Useful Post: [ View ] Gift jkolner Ad-Free
18th February 2018, 11:41 PM |#9  
Thank you for this! I was using the original Adhell until recently it stopped working. Got everything setup per your instructions and it works very well. Love the clean interface and choice of dark or light themes. Keep up the good work!

Sent from my SM-G955U using Tapatalk
19th February 2018, 12:06 AM |#10  
Mike B.'s Avatar
Recognized Contributor
/
Thanks Meter: 3,031
 
10
More
Quote:
Originally Posted by jkolner

Just switched from AdHell to SABS and everything works perfectly.

This is my custom blocked hostes:
...

That's a LOT of hosts and seems to be a gross overkill with no obvious benefit. If you study the contents of those lists you might discover that there are multiple redundant entries (especially since they don't use wildcards). Try using solely the default standard package and you might be surprised by how efficient it is.
The Following 5 Users Say Thank You to Mike B. For This Useful Post: [ View ] Gift Mike B. Ad-Free
19th February 2018, 12:19 AM |#11  
For the enabling and disabling of SABS, I recall on the original Adhell this process would take a few seconds but it seems to take longer on SABS. I've whitelisted googleadservices.com disabled and tried re-enabling but it seems to just hang. Any suggestions?

Sent from my SM-G955U using Tapatalk
Thread Closed Subscribe to Thread

Tags
adblock, adhell, disabler, knox, needlegames, sabs, samsung
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes