[Epic 4G Android Development] Fnorder:
This is more or less an addon to the official CyanongenMod 7.2-release or RC2 ( found here) that adds a number of enhancements written by others or myself. As the name implies, it's geared toward privacy and user control.

**************

*** Features ***

PDroid 1.32 These framework patches allow you to configure privacy settings on a per-app basis after the app is installed. Unlike CM7's feature, one can assign random or custom spoofed values (so the app doesn't crash) for location, meid, serial numbers and phone numbers.

AdBlockPlus filtering in webcore For browsing, this is more powerful than the traditional /etc/hosts blacklisting, as it allows one to filter specific urls with pattern matching. Filters for just javascript or third party urls are possible (ex: ||twitter.com^$third-party or *counter*$script ). This uses the same filter sources as AdBlockPlus for Firefox; the syntax is fully compatible except for $doman=host.com flags)

Custom url in QuickSearchBox Use a GET compatible search engine whenever you type from home. Replace google with something more versatile like w.yubnub.org:80/p****r/p****?command=%s. Warning, google apps install clobbers this, see below.

app firewall script Unlike droidwall, this runs from init.d -before- any android app can load. However, this is a pure bash script with no gui (yet). Thankfully, it runs on an Epic, where one can feasibly type 'fw allow org.connectbot', especially with bash_completion and corrected key layout (see below). It can also pull allowed apps from droidwall's config

Tweaked key layout The ':)' and 'SYM' keys are mapped to DPAD_CENTER and RIGHT_SHIFT, instead of @ and =. DPAD_CENTER clicks highlighted links in browsers (allowing full keyboard navigation), and is a CTRL modifier in ConnectBot and Terminal. RIGHT_SHIFT can be set to TAB in ConnectBot, and the included Terminal mod.

Tweaked Terminal SYM(right_shift) sends TAB.

Redone bashrc with bash_completion 'pkill com.rov<TAB>' instead of typing 'pkill com.rovio.angrybirdsspace.premium', 'getprop ro.sf<TAB>' for ro.sf.lcd_density', or 'firewall de<TAB> com.sw<TAB>' for 'firewall deny com.swype.android.inputmethod'

fixed /system/bin/iptables The one in CM7 is broken.

*****************

*** How to install ***

Already installed CM 7.2 tested with RC2 and release

1: BACKUP! (Warning, this WILL overwrite themed frameworks)

2: Flash tinfoilhat-4-cm7.2epicmtd.zip

3: Reboot. Wait a long time as dalvik-cache updates.

Clean install from another rom

1: ""

2: Flash the original cm-7.2.0-epicmtd.zip or the older epic-CM7.2-RC2.zip, then flash tinfoilhat-3-cm7.2epicmtd.zip

-OR-

obsolete Flash the pre-patched CM 7.2 RC2 update: epic-CM7.2-RC2-tinfoilhat-3.zip

3: Install official gapps, or gapps-vend-uns-gb-20110828-signed.zip which will not override QuickSearchBox, and includes a Play Store modified for LCD density friendliness.

3: Reboot

Removal

Flash reverse-tinfoilhat-3.zip This is only recommended if you came from epic-CM7.2-RC2.

***********

*** FAQ ***

How do I use the firewall? In terminal, type

# fw --help

Usage: fw (start|stop|status)
start, stop reinitialize firewall
or: fw (enable|disable)
enable enable firewall at bootup
disable disable firewall at bootup
or: fw (allow|noallow|deny|nodeny) [apps]
allow com.package add app to allow list
a ...
noallow com.package remove from allow list
na, a- ...
deny com.package add app to blacklist
d ...
nodeny com.package remove from blacklist
nd, d- ...
UIDs over $allowmax can only access the network if they are in the allow list,
UNLESS they are in the deny list.
Low UIDs will always have network access unless they are in the deny list.

Where is the adblock filter? / How do I update it? It's located in /data/adblock.txt and should have global read-only permissions. The

upadblock

command will update to the newest easyprivacy ruleset. All custom rules should be below the '!-- Custom stuff below ...' line at the end.

Gingerbread? That is so last year, Y U NO ICS? CM9 is missing alot of CM7's great features, plus ICS has an annoying task switcher and scrolls like a fat drunken pig.

***********

** Changes **

Jul 29 2012 Build 4:

* updated framework to cyanogen 7.2 stable release

* fixed stupid typos in firewall script

* fixed upadblock and switched to fanboy's tracking list

* added code to let google maps 'networklocationservice' die when not in use: https://github.com/nadlabak/android_...e495f8c9495c1e

Jul 31 2012Silly bootlogo created:

***********

*** Todo ***

fw allow -new grant access to app most recently updated

ICS/JB/AOKP/etc. Someday. Maybe.

*** In the works as optional addons ***

optware optware has more than 1300 compatible linux apps optimized for embedded environments, that can be installed with 'ipkg install whatever'

'websnoop' perl script that wraps ngrep to filter by app. Spits out highlights of HTTP traffic (URLs, cookies, etc). This is what was used to catch Dolphin's URL forwarding:

# ws -new 1
Matching uid 10048 (shared mgeek.dolphin.browser: mobi.mgeek.TunnyBrowser)
(sh:mgeek.dolphin.browser:10048) [G] www.google.com/search?q=wut
(sh:mgeek.dolphin.browser:10048) [G] en.mywebzines.com:80/v3/columns?u=http%3A%2F%2Fwww.google.com%2Fsearch%3Fq%3Dwut

ncurses firewall gui Faster than an android gui if done right

*****************

*** Files & sums ****

Patch install: http://epic-cm7-tinfoilhat.googlecode.com/files/tinfoilhat-4-cm7.2epicmtd.zip 7e7c987f8c6757dc910366b2bd900cfc3fd69f6c

obsolete

Full CM7.2 RC2 install: http://epic-cm7-tinfoilhat.googlecode.com/files/epic-CM7.2-RC2-tinfoilhat-3.zip 5787fc7ed779e5c05117c0cd00952beddaf41c70

Uninstall: http://epic-cm7-tinfoilhat.googlecode.com/files/reverse-tinfoilhat-3.zip 44ec21efe95ee304f5e8c445fe35f95c6686e523

google apps: http://epic-cm7-tinfoilhat.googlecode.com/files/gapps-vend-uns-gb-20110828-signed.zip 49016443c5ee4cc3fa4ff25a54459c269b1a7c2e

Source patches and build instructions: http://epic-cm7-tinfoilhat.googlecode.com/files/tinfoilhat-3-src.zip 6ceee12208aa849c47f4dfb0db47138a0846e570