Compare commits
170 Commits
extension
...
EXPERIMENT
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
220b6756b6 | ||
|
|
7f7f021e45 | ||
|
|
f9b02fe13f | ||
|
|
6026ee3ec6 | ||
|
|
3c508f4190 | ||
|
|
91abc574d3 | ||
|
|
bae0412ebc | ||
|
|
e73a5969db | ||
|
|
e764c7b773 | ||
|
|
7c62c8ecda | ||
|
|
d13e2317dd | ||
|
|
7ff4eb5e37 | ||
|
|
e6928d64ce | ||
|
|
ad373eface | ||
|
|
d52e79c72e | ||
|
|
71b9b9c6ec | ||
|
|
f8ff48f723 | ||
|
|
8b089ad49e | ||
|
|
afdb51370e | ||
|
|
2ff2e462a9 | ||
|
|
41f4f80a4d | ||
|
|
aee8cdbe5f | ||
|
|
15a2386981 | ||
|
|
8aefcff4b1 | ||
|
|
1b35c8dc8b | ||
|
|
e7ea163a64 | ||
|
|
2b95573f7a | ||
|
|
51aa9a97b1 | ||
|
|
8737093b6d | ||
|
|
688b9ca309 | ||
|
|
ac7336f669 | ||
|
|
51a63dfb35 | ||
|
|
2c328bec86 | ||
|
|
fa54305df3 | ||
|
|
d7036f7a96 | ||
|
|
111ecebe6c | ||
|
|
272ff689e7 | ||
|
|
3b544d0e25 | ||
|
|
7b24afba86 | ||
|
|
5b8c3e4b2a | ||
|
|
86b6413a9b | ||
|
|
cd15ee07c1 | ||
|
|
59ca9d1d7f | ||
|
|
94feece528 | ||
|
|
fc1cce1f4b | ||
|
|
5218f18599 | ||
|
|
b79044bcce | ||
|
|
8453c4092c | ||
|
|
a90e7db310 | ||
|
|
eacb19034a | ||
|
|
14b40177fe | ||
|
|
f54d989ea7 | ||
|
|
99f6029578 | ||
|
|
50097f335a | ||
|
|
d943bf98ca | ||
|
|
1504d65ba7 | ||
|
|
7ef6e9149d | ||
|
|
a8117ce0fc | ||
|
|
1430d73103 | ||
|
|
b5de7de981 | ||
|
|
59dc5d65e0 | ||
|
|
6165131c66 | ||
|
|
a5db548ad5 | ||
|
|
7dfd857b43 | ||
|
|
008025d76f | ||
|
|
755a47d6f2 | ||
|
|
97f3dbd71f | ||
|
|
ffd7bfb834 | ||
|
|
ab58ec31ff | ||
|
|
da9f7695a7 | ||
|
|
a6481d7bd7 | ||
|
|
d9025e5853 | ||
|
|
27328d5141 | ||
|
|
b3967525e5 | ||
|
|
5e55b9068f | ||
|
|
c467296aad | ||
|
|
dfe9ff50ee | ||
|
|
72ca56e9a1 | ||
|
|
b62d64bb0f | ||
|
|
8424727dae | ||
|
|
10f02140a3 | ||
|
|
c66d08d9d8 | ||
|
|
bf9e8cae14 | ||
|
|
5ce0477d46 | ||
|
|
13af013cbd | ||
|
|
ff1451c0dc | ||
|
|
986b003f20 | ||
|
|
9171c454bc | ||
|
|
2099c1f5fa | ||
|
|
1edb0c3e0e | ||
|
|
ca89bc017b | ||
|
|
d5fd31eba9 | ||
|
|
12f124d259 | ||
|
|
55a7be91c6 | ||
|
|
98d1a80347 | ||
|
|
8aae087969 | ||
|
|
d2d272f17a | ||
|
|
0429c2bab5 | ||
|
|
2d24c57c8e | ||
|
|
f0a4001b53 | ||
|
|
b678d1434a | ||
|
|
ee2a7cc93d | ||
|
|
0c3fe5b37d | ||
|
|
b8a4633113 | ||
|
|
b4b09ea5da | ||
|
|
4df405978f | ||
|
|
cb821a72ad | ||
|
|
8218591986 | ||
|
|
9a03137a67 | ||
|
|
03bba27c14 | ||
|
|
9998692bbd | ||
|
|
506d2035cb | ||
|
|
5783feb348 | ||
|
|
afb3ca87b4 | ||
|
|
dc08fda98b | ||
|
|
c3c0a8ae28 | ||
|
|
2e95100bf4 | ||
|
|
cd02426571 | ||
|
|
1eece32f73 | ||
|
|
a4b99698af | ||
|
|
075d5e4181 | ||
|
|
8b3d0babda | ||
|
|
ac3036e819 | ||
|
|
0e60f158ce | ||
|
|
e438fff266 | ||
|
|
c244dc9fe7 | ||
|
|
ddc6704351 | ||
|
|
8adf9b83a4 | ||
|
|
e22abb872e | ||
|
|
8f70bc346d | ||
|
|
30909d1353 | ||
|
|
a218f0d580 | ||
|
|
0a0f063f1b | ||
|
|
50ab03e195 | ||
|
|
3cdc0d674a | ||
|
|
c71bdbb77d | ||
|
|
a5540bc94d | ||
|
|
845c369f77 | ||
|
|
3d2377011d | ||
|
|
509f9a991a | ||
|
|
1b3fd56ced | ||
|
|
2307beb365 | ||
|
|
936344c794 | ||
|
|
0f043231af | ||
|
|
65361e8cc0 | ||
|
|
231c60dc75 | ||
|
|
9bd9764a6f | ||
|
|
2b4466aeab | ||
|
|
67654f8f56 | ||
|
|
0bfbef932d | ||
|
|
449653b221 | ||
|
|
39486bd672 | ||
|
|
44c82c0149 | ||
|
|
f29e5ede4c | ||
|
|
747db01cb5 | ||
|
|
c045eb9b20 | ||
|
|
2c59bf697b | ||
|
|
5367021b98 | ||
|
|
3887966163 | ||
|
|
17497df47e | ||
|
|
6406405f2f | ||
|
|
365f3c5c31 | ||
|
|
a1394bedde | ||
|
|
5d71698e16 | ||
|
|
b477d3d181 | ||
|
|
c322a85fe0 | ||
|
|
ae97ddee18 | ||
|
|
23fe6b64f1 | ||
|
|
dd9b762e3f | ||
|
|
94d728661e |
8
.gitignore
vendored
Normal file
8
.gitignore
vendored
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
build
|
||||||
|
*.deb
|
||||||
|
*.tgz
|
||||||
|
./I2P/
|
||||||
|
i2pversion_override
|
||||||
|
*.crl
|
||||||
|
*.crt
|
||||||
|
*.pem
|
||||||
10
Dockerfile
Normal file
10
Dockerfile
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
FROM alpine:latest
|
||||||
|
RUN apk update && apk add firefox make curl musl-locales dbus-x11 font-ubuntu-nerd jq --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing
|
||||||
|
ADD . /src
|
||||||
|
WORKDIR /src
|
||||||
|
RUN make profile.tgz # && \
|
||||||
|
RUN chown -R 1000:1000 /src/build/profile # && \
|
||||||
|
RUN chmod -R +w /src/build/profile
|
||||||
|
RUN ls -lah /src/build/profile
|
||||||
|
#USER 1000
|
||||||
|
CMD sh -c 'cd build/profile && ./i2pbrowser.sh'
|
||||||
@@ -1 +1 @@
|
|||||||
https://www.eff.org/files/https-everywhere-2019.1.31-eff.xpi
|
https://addons.mozilla.org/firefox/downloads/file/3716461/2021.7.13/https_everywhere-2021.7.13-an+fx.xpi
|
||||||
|
|||||||
241
Makefile
241
Makefile
@@ -1,11 +1,85 @@
|
|||||||
all: profile.tgz install.exe
|
-include i2pversion
|
||||||
|
-include i2pversion_override
|
||||||
|
|
||||||
install.exe: profile build/licenses
|
-include config.mk
|
||||||
|
|
||||||
|
preset=`rm .version; make .version`
|
||||||
|
|
||||||
|
include .version
|
||||||
|
|
||||||
|
PROFILE_VERSION=$(MAJOR).$(MINOR).$(BUILD)
|
||||||
|
|
||||||
|
all: .version install.exe
|
||||||
|
|
||||||
|
tag:
|
||||||
|
git tag $(PROFILE_VERSION)
|
||||||
|
|
||||||
|
.version:
|
||||||
|
sed 's|!define VERSION||g' src/nsis/i2pbrowser-version.nsi | sed 's| |=|g' > .version
|
||||||
|
make version.txt src/nsis/i2pbrowser_jpackage.nsi
|
||||||
|
|
||||||
|
version.txt:
|
||||||
|
echo "$(PROFILE_VERSION)" > src/profile/version.txt
|
||||||
|
echo "$(PROFILE_VERSION)" > src/app-profile/version.txt
|
||||||
|
|
||||||
|
src/nsis/i2pbrowser_jpackage.nsi:
|
||||||
|
echo "!define I2P_VERSION $(I2P_VERSION)" > src/nsis/i2pbrowser_jpackage.nsi
|
||||||
|
|
||||||
|
jpackage: .version I2P all
|
||||||
|
|
||||||
|
help: .version
|
||||||
|
@echo "I2P-Profile-Installer-$(PROFILE_VERSION)"
|
||||||
|
@echo "$(SIGNER)"
|
||||||
|
@echo "$(I2P_VERSION)"
|
||||||
|
@echo "$(MAJOR).$(MINOR).$(BUILD)"
|
||||||
|
@echo "$(preset)"
|
||||||
|
|
||||||
|
prep: profile.tgz app-profile.tgz profile build/licenses build/I2P build/I2P/config launchers
|
||||||
cp src/nsis/*.nsi build
|
cp src/nsis/*.nsi build
|
||||||
cp src/nsis/*.nsh build
|
cp src/nsis/*.nsh build
|
||||||
cp src/icons/*.ico build
|
cp src/icons/*.ico build
|
||||||
|
|
||||||
|
install.exe: prep
|
||||||
cd build && makensis i2pbrowser-installer.nsi && cp I2P-Profile-Installer-*.exe ../ && echo "built windows installer"
|
cd build && makensis i2pbrowser-installer.nsi && cp I2P-Profile-Installer-*.exe ../ && echo "built windows installer"
|
||||||
|
|
||||||
|
export RES_DIR="../i2p.i2p/installer/resources"
|
||||||
|
export PKG_DIR="../i2p.i2p/pkg-temp"
|
||||||
|
export I2P_JBIGI="../i2p.i2p/installer/lib/jbigi"
|
||||||
|
|
||||||
|
distclean: clean
|
||||||
|
rm -rf I2P
|
||||||
|
|
||||||
|
I2P:
|
||||||
|
./build.sh
|
||||||
|
|
||||||
|
build/I2P: build
|
||||||
|
rm -rf build/I2P
|
||||||
|
cp -rv I2P build/I2P ; true
|
||||||
|
cp "$(I2P_JBIGI)"/*windows*.dll build/I2P/runtime/lib; true
|
||||||
|
|
||||||
|
configdir: src/I2P/config
|
||||||
|
|
||||||
|
src/I2P/config:
|
||||||
|
mkdir src/I2P/config
|
||||||
|
rm -rf src/I2P/config/geoip src/I2P/config/webapps src/I2P/config/certificates
|
||||||
|
echo true | tee src/I2P/config/jpackaged
|
||||||
|
cp -v $(RES_DIR)/clients.config src/I2P/config/
|
||||||
|
cp -v $(RES_DIR)/i2ptunnel.config src/I2P/config/
|
||||||
|
cp -v $(RES_DIR)/wrapper.config src/I2P/config/
|
||||||
|
#grep -v 'router.updateURL' $(RES_DIR)/router.config > src/I2P/config/router.config
|
||||||
|
cat router.config >> src/I2P/config/router.config
|
||||||
|
cp -v $(RES_DIR)/hosts.txt src/I2P/config/hosts.txt
|
||||||
|
cp -R $(RES_DIR)/certificates src/I2P/config/certificates
|
||||||
|
cp -R $(RES_DIR)/eepsite src/I2P/config/eepsite
|
||||||
|
mkdir -p src/I2P/config/geoip
|
||||||
|
cp -v $(RES_DIR)/GeoLite2-Country.mmdb.gz src/I2P/config/geoip/GeoLite2-Country.mmdb.gz
|
||||||
|
cp -R "$(PKG_DIR)"/webapps src/I2P/config/webapps
|
||||||
|
cd src/I2P/config/geoip && gunzip GeoLite2-Country.mmdb.gz; cd ../../..
|
||||||
|
|
||||||
|
build/I2P/config: build/I2P src/I2P/config
|
||||||
|
cp -rv src/I2P/config build/I2P/config ; true
|
||||||
|
cp -rv src/I2P/config build/I2P/.i2p ; true
|
||||||
|
|
||||||
#
|
#
|
||||||
# Warning: a displayed license file of more than 28752 bytes
|
# Warning: a displayed license file of more than 28752 bytes
|
||||||
# will cause makensis V3.03 to crash.
|
# will cause makensis V3.03 to crash.
|
||||||
@@ -14,12 +88,11 @@ install.exe: profile build/licenses
|
|||||||
build/licenses: build
|
build/licenses: build
|
||||||
mkdir -p build/licenses
|
mkdir -p build/licenses
|
||||||
cp license/* build/licenses
|
cp license/* build/licenses
|
||||||
cp LICENSE build/licenses/MIT.txt
|
cp LICENSE.md build/licenses/MIT.txt
|
||||||
unix2dos build/licenses/LICENSE.index
|
unix2dos build/licenses/LICENSE.index
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -rf build profile-*.tgz I2P-Profile-Installer-*.exe
|
rm -rf build app-profile-*.tgz profile-*.tgz I2P-Profile-Installer-*.exe *.deb src/I2P/config *.su3
|
||||||
|
|
||||||
|
|
||||||
build:
|
build:
|
||||||
@echo "creating build directory"
|
@echo "creating build directory"
|
||||||
@@ -27,9 +100,11 @@ build:
|
|||||||
|
|
||||||
profile: build/profile/user.js build/profile/prefs.js build/profile/bookmarks.html build/profile/storage-sync.sqlite copy-xpi
|
profile: build/profile/user.js build/profile/prefs.js build/profile/bookmarks.html build/profile/storage-sync.sqlite copy-xpi
|
||||||
|
|
||||||
profile.tgz: profile
|
profile.tgz: .version profile
|
||||||
$(eval PROFILE_VERSION := $(shell cat src/profile/version.txt))
|
# $(eval PROFILE_VERSION := $(shell cat src/profile/version.txt))
|
||||||
@echo "building profile tarball $(PROFILE_VERSION)"
|
@echo "building profile tarball $(PROFILE_VERSION)"
|
||||||
|
sh -c 'ls I2P && cp -rv build/I2P build/profile/I2P'; true
|
||||||
|
install -m755 src/unix/i2pbrowser.sh build/profile/i2pbrowser.sh
|
||||||
cd build && tar -czf profile-$(PROFILE_VERSION).tgz profile && cp profile-$(PROFILE_VERSION).tgz ../
|
cd build && tar -czf profile-$(PROFILE_VERSION).tgz profile && cp profile-$(PROFILE_VERSION).tgz ../
|
||||||
|
|
||||||
build/profile/user.js: build/profile src/profile/user.js
|
build/profile/user.js: build/profile src/profile/user.js
|
||||||
@@ -44,22 +119,160 @@ build/profile/bookmarks.html: build/profile src/profile/bookmarks.html
|
|||||||
build/profile/storage-sync.sqlite: build/profile src/profile/storage-sync.sqlite
|
build/profile/storage-sync.sqlite: build/profile src/profile/storage-sync.sqlite
|
||||||
cp src/profile/storage-sync.sqlite build/profile/storage-sync.sqlite
|
cp src/profile/storage-sync.sqlite build/profile/storage-sync.sqlite
|
||||||
|
|
||||||
copy-xpi: build/NoScript.xpi build/HTTPSEverywhere.xpi build/i2ppb@eyedeekay.github.io.xpi build/profile/extensions
|
copy-xpi: build/NoScript.xpi build/HTTPSEverywhere.xpi build/i2prhz@eyedeekay.github.io.xpi build/profile/extensions
|
||||||
cp build/NoScript.xpi "build/profile/extensions/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
cp build/NoScript.xpi "build/profile/extensions/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||||
cp build/HTTPSEverywhere.xpi "build/profile/extensions/https-everywhere-eff@eff.org.xpi"
|
cp build/HTTPSEverywhere.xpi "build/profile/extensions/https-everywhere-eff@eff.org.xpi"
|
||||||
cp build/i2ppb@eyedeekay.github.io.xpi build/profile/extensions/i2ppb@eyedeekay.github.io.xpi
|
cp build/i2prhz@eyedeekay.github.io.xpi build/profile/extensions/i2prhz@eyedeekay.github.io.xpi
|
||||||
|
|
||||||
build/i2ppb@eyedeekay.github.io.xpi:
|
app-profile: .version build/app-profile/user.js build/app-profile/prefs.js build/app-profile/chrome/userChrome.css build/app-profile/bookmarks.html build/app-profile/storage-sync.sqlite copy-app-xpi
|
||||||
curl -L `cat i2psetproxy.url` > build/i2ppb@eyedeekay.github.io.xpi
|
|
||||||
|
app-profile.tgz: app-profile
|
||||||
|
# $(eval PROFILE_VERSION := $(shell cat src/app-profile/version.txt))
|
||||||
|
@echo "building app-profile tarball $(PROFILE_VERSION)"
|
||||||
|
sh -c 'ls I2P && cp -rv build/I2P build/app-profile/I2P'; true
|
||||||
|
install -m755 src/unix/i2pconfig.sh build/app-profile/i2pconfig.sh
|
||||||
|
cd build && tar -czf app-profile-$(PROFILE_VERSION).tgz app-profile && cp app-profile-$(PROFILE_VERSION).tgz ../
|
||||||
|
|
||||||
|
build/app-profile/user.js: build/app-profile src/app-profile/user.js
|
||||||
|
cp src/app-profile/user.js build/app-profile/user.js
|
||||||
|
|
||||||
|
build/app-profile/prefs.js: build/app-profile src/app-profile/prefs.js
|
||||||
|
cp src/app-profile/prefs.js build/app-profile/prefs.js
|
||||||
|
|
||||||
|
build/app-profile/chrome/userChrome.css: build/app-profile/chrome src/app-profile/chrome/userChrome.css
|
||||||
|
cp src/app-profile/chrome/userChrome.css build/app-profile/chrome/userChrome.css
|
||||||
|
|
||||||
|
build/app-profile/bookmarks.html: build/app-profile src/app-profile/bookmarks.html
|
||||||
|
cp src/app-profile/bookmarks.html build/app-profile/bookmarks.html
|
||||||
|
|
||||||
|
build/app-profile/storage-sync.sqlite: build/app-profile src/app-profile/storage-sync.sqlite
|
||||||
|
cp src/app-profile/storage-sync.sqlite build/app-profile/storage-sync.sqlite
|
||||||
|
|
||||||
|
copy-app-xpi: build/NoScript.xpi build/HTTPSEverywhere.xpi build/i2prhz@eyedeekay.github.io.xpi build/app-profile/extensions
|
||||||
|
cp build/HTTPSEverywhere.xpi "build/app-profile/extensions/https-everywhere-eff@eff.org.xpi"
|
||||||
|
cp build/i2prhz@eyedeekay.github.io.xpi build/app-profile/extensions/i2prhz@eyedeekay.github.io.xpi
|
||||||
|
|
||||||
|
build-extensions: build/i2prhz@eyedeekay.github.io.xpi build/NoScript.xpi build/HTTPSEverywhere.xpi
|
||||||
|
|
||||||
|
build/i2prhz@eyedeekay.github.io.xpi: i2psetproxy.url
|
||||||
|
curl -L `cat i2psetproxy.url` > build/i2prhz@eyedeekay.github.io.xpi
|
||||||
|
|
||||||
build/NoScript.xpi: NoScript.url
|
build/NoScript.xpi: NoScript.url
|
||||||
curl `cat NoScript.url` > build/NoScript.xpi
|
curl -L `cat NoScript.url` > build/NoScript.xpi
|
||||||
|
|
||||||
build/HTTPSEverywhere.xpi : HTTPSEverywhere.url
|
build/HTTPSEverywhere.xpi: HTTPSEverywhere.url
|
||||||
curl `cat HTTPSEverywhere.url` > build/HTTPSEverywhere.xpi
|
curl -L `cat HTTPSEverywhere.url` > build/HTTPSEverywhere.xpi
|
||||||
|
|
||||||
|
clean-extensions:
|
||||||
|
rm -fv i2psetproxy.url NoScript.url HTTPSEverywhere.url
|
||||||
|
|
||||||
|
extensions:HTTPSEverywhere.url NoScript.url i2psetproxy.url
|
||||||
|
|
||||||
|
HTTPSEverywhere.url:
|
||||||
|
@echo "https://addons.mozilla.org/firefox/downloads/file/3716461/"`./amo-version.sh https-everywhere`"/https_everywhere-"`./amo-version.sh https-everywhere`"-an+fx.xpi" > HTTPSEverywhere.url
|
||||||
|
|
||||||
|
NoScript.url:
|
||||||
|
@echo "https://addons.mozilla.org/firefox/downloads/file/3534184/"`./amo-version.sh noscript`"/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi" > NoScript.url
|
||||||
|
|
||||||
|
i2psetproxy.url:
|
||||||
|
@echo "https://addons.mozilla.org/firefox/downloads/file/3784917/"`./amo-version.sh i2pipb-rhizome-variant`"/i2prhz@eyedeekay.github.io" > i2psetproxy.url
|
||||||
|
|
||||||
|
#i2ppb@eyedeekay.github.io.xpi
|
||||||
|
|
||||||
build/profile/extensions: build/profile
|
build/profile/extensions: build/profile
|
||||||
mkdir -p build/profile/extensions
|
mkdir -p build/profile/extensions
|
||||||
|
|
||||||
build/profile: build
|
build/profile: build
|
||||||
mkdir -p build/profile
|
mkdir -p build/profile
|
||||||
|
|
||||||
|
build/win:
|
||||||
|
mkdir -p build/win/
|
||||||
|
|
||||||
|
build/win/i2pbrowser.bat:
|
||||||
|
cp src/win/i2pbrowser.bat build/win/i2pbrowser.bat
|
||||||
|
|
||||||
|
build/win/i2pconfig.bat:
|
||||||
|
cp src/win/i2pconfig.bat build/win/i2pconfig.bat
|
||||||
|
|
||||||
|
build/win/i2pbrowser-private.bat:
|
||||||
|
cp src/win/i2pbrowser-private.bat build/win/i2pbrowser-private.bat
|
||||||
|
|
||||||
|
launchers: build/win build/win/i2pbrowser.bat build/win/i2pbrowser-private.bat build/win/i2pconfig.bat
|
||||||
|
|
||||||
|
build/app-profile/chrome: build/app-profile
|
||||||
|
mkdir -p build/app-profile/chrome
|
||||||
|
|
||||||
|
build/app-profile/extensions: build/app-profile
|
||||||
|
mkdir -p build/app-profile/extensions
|
||||||
|
|
||||||
|
build/app-profile: build
|
||||||
|
mkdir -p build/app-profile
|
||||||
|
|
||||||
|
install:
|
||||||
|
rm -rfv /etc/i2pbrowser \
|
||||||
|
/var/lib/i2pbrowser
|
||||||
|
mkdir -p /etc/i2pbrowser \
|
||||||
|
/var/lib/i2pbrowser
|
||||||
|
install -m644 src/unix/i2pbrowserrc /etc/i2pbrowser/i2pbrowserrc
|
||||||
|
install -m644 src/unix/i2pbrowserdebianrc /etc/i2pbrowser/i2pbrowserdebianrc
|
||||||
|
install -m755 build/profile/i2pbrowser.sh /usr/local/bin/i2pbrowser
|
||||||
|
install -m755 build/app-profile/i2pconfig.sh /usr/local/bin/i2pconfig
|
||||||
|
install -m755 src/unix/i2p-config-service-setup.sh /usr/local/bin/i2p-config-service-setup
|
||||||
|
cp -vr build/profile /var/lib/i2pbrowser/profile
|
||||||
|
cp -vr build/app-profile /var/lib/i2pbrowser/app-profile
|
||||||
|
cp -vr src/icons /var/lib/i2pbrowser/icons
|
||||||
|
cp src/unix/desktop/i2pbrowser.desktop /usr/share/applications
|
||||||
|
cp src/unix/desktop/i2pconfig.desktop /usr/share/applications
|
||||||
|
|
||||||
|
uninstall:
|
||||||
|
rm -rfv /etc/i2pbrowser \
|
||||||
|
/var/lib/i2pbrowser \
|
||||||
|
/etc/i2pbrowser/i2pbrowserrc \
|
||||||
|
/usr/local/bin/i2pbrowser \
|
||||||
|
/usr/local/bin/i2pconfig \
|
||||||
|
/usr/local/bin/i2p-config-service-setup \
|
||||||
|
/usr/share/applications/i2pbrowser.desktop \
|
||||||
|
/usr/share/applications/i2pconfig.desktop
|
||||||
|
|
||||||
|
checkinstall: version
|
||||||
|
checkinstall \
|
||||||
|
--default \
|
||||||
|
--install=no \
|
||||||
|
--fstrans=yes \
|
||||||
|
--pkgname=i2p-firefox \
|
||||||
|
--pkgversion=$(PROFILE_VERSION) \
|
||||||
|
--pkggroup=net \
|
||||||
|
--pkgrelease=1 \
|
||||||
|
--pkgsource="https://i2pgit.org/i2p-hackers/i2p.firefox" \
|
||||||
|
--maintainer="$(SIGNER)" \
|
||||||
|
--requires="firefox,wget" \
|
||||||
|
--suggests="i2p,i2p-router,syndie,tor,tsocks" \
|
||||||
|
--nodoc \
|
||||||
|
--deldoc=yes \
|
||||||
|
--deldesc=yes \
|
||||||
|
--backup=no
|
||||||
|
|
||||||
|
GOPATH=$(HOME)/go
|
||||||
|
|
||||||
|
$(GOPATH)/src/i2pgit.org/idk/su3-tools/su3-tools:
|
||||||
|
git clone https://i2pgit.org/idk/su3-tools $(GOPATH)/src/i2pgit.org/idk/su3-tools; true
|
||||||
|
git pull --all
|
||||||
|
cd $(GOPATH)/src/i2pgit.org/idk/su3-tools && \
|
||||||
|
go mod vendor && go build
|
||||||
|
|
||||||
|
su3: $(GOPATH)/src/i2pgit.org/idk/su3-tools/su3-tools
|
||||||
|
$(GOPATH)/src/i2pgit.org/idk/su3-tools/su3-tools -name "I2P-Profile-Installer-$(PROFILE_VERSION)" -signer "$(SIGNER)" -version "$(I2P_VERSION)"
|
||||||
|
|
||||||
|
docker:
|
||||||
|
docker build -t geti2p/i2p.firefox .
|
||||||
|
|
||||||
|
xhost:
|
||||||
|
xhost + local:docker
|
||||||
|
|
||||||
|
run: docker xhost
|
||||||
|
docker run -it --rm \
|
||||||
|
--net=host \
|
||||||
|
-e DISPLAY=unix$(DISPLAY) \
|
||||||
|
-v /tmp/.X11-unix:/tmp/.X11-unix \
|
||||||
|
geti2p/i2p.firefox firefox --profile /src/build/profile
|
||||||
|
|
||||||
@@ -1 +1 @@
|
|||||||
https://secure.informaction.com/download/releases/noscript-10.2.1.xpi
|
https://addons.mozilla.org/firefox/downloads/file/3534184/11.2.11/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi
|
||||||
|
|||||||
13
README
13
README
@@ -1,13 +0,0 @@
|
|||||||
To build this, you will need the following software packages (all available in Debian) :
|
|
||||||
|
|
||||||
* make
|
|
||||||
* nsis
|
|
||||||
* dos2unix
|
|
||||||
* curl
|
|
||||||
|
|
||||||
Before you build, you should update the files "NoScript.url" and "HTTPSEverywhere.url" to point to the latest direct download links of the respective plugins. If those have changed, it's a good idea to check those files back in to keep them as current as possible.
|
|
||||||
|
|
||||||
After that just type "make". This will produce two files:
|
|
||||||
|
|
||||||
profile.tgz - the raw firefox profile.
|
|
||||||
install.exe - the windows installer.
|
|
||||||
249
README.md
Normal file
249
README.md
Normal file
@@ -0,0 +1,249 @@
|
|||||||
|
I2P Browsing Profile for Firefox
|
||||||
|
================================
|
||||||
|
|
||||||
|
Features:
|
||||||
|
---------
|
||||||
|
|
||||||
|
- Automatically select an up-to-date, secure Firefox or Tor Browser(On Windows) variant
|
||||||
|
- Automatically configure a profile for I2P
|
||||||
|
- Automatically block-list all non-I2P local destinations
|
||||||
|
- Enable first-party isolation, anti-fingerprinting, letterboxing
|
||||||
|
- Automatically sandbox I2P, Non-I2P, and I2P-Application cookiestores
|
||||||
|
|
||||||
|
Build Dependencies:
|
||||||
|
-------------------
|
||||||
|
|
||||||
|
To build this, you will need the following software packages (all available in Debian) :
|
||||||
|
|
||||||
|
* make
|
||||||
|
* nsis
|
||||||
|
* dos2unix
|
||||||
|
* curl
|
||||||
|
* jq
|
||||||
|
|
||||||
|
to build a Debian package, you'll also need
|
||||||
|
|
||||||
|
* checkinstall
|
||||||
|
|
||||||
|
Preparation
|
||||||
|
-----------
|
||||||
|
|
||||||
|
Before you build, run the targets
|
||||||
|
|
||||||
|
|
||||||
|
make clean-extensions
|
||||||
|
make extensions
|
||||||
|
|
||||||
|
to update the extensions to point to their latest versions.
|
||||||
|
|
||||||
|
Windows Build
|
||||||
|
-------------
|
||||||
|
|
||||||
|
After installing the dependencies and completing the preparations,
|
||||||
|
just run `make`. This will produce three files:
|
||||||
|
|
||||||
|
profile.tgz - the firefox profile, plus a shell script which will
|
||||||
|
launch it if Firefox is found in the $PATH on Unix-Like operating
|
||||||
|
systems.
|
||||||
|
app-profile.tgz - the Firefox profile plus a launcher shell script,
|
||||||
|
which will launch a *modified* Firefox without a URL bar as a router
|
||||||
|
console wrapper.
|
||||||
|
install.exe - the windows installer, which sets up shortcuts to
|
||||||
|
launch Firefox on Windows.
|
||||||
|
|
||||||
|
Unix Support
|
||||||
|
------------
|
||||||
|
|
||||||
|
It is possible to use these profiles on Linux and possibly other
|
||||||
|
Unixes, if Firefox is already installed on the system. It can be
|
||||||
|
installed system-wide using the `make install` target. Running
|
||||||
|
`make install` requires root, and requires `make` to have been run
|
||||||
|
first. To install on Unix, system-wide, run:
|
||||||
|
|
||||||
|
make
|
||||||
|
sudo make install
|
||||||
|
|
||||||
|
To run without installing them system wide, unpack the `profile*.tgz`
|
||||||
|
to a location of your choice and run the `i2pbrowser.sh` script. This
|
||||||
|
will start a Firefox profile configured to use I2P.
|
||||||
|
|
||||||
|
tar xvf profile-0.3.tgz
|
||||||
|
cd profile
|
||||||
|
./i2pbrowser.sh
|
||||||
|
|
||||||
|
If you want to run the app-like i2pconfig browser, then follow the
|
||||||
|
same steps with app-profile*.tgz.
|
||||||
|
|
||||||
|
tar xvf app-profile-0.3.tgz
|
||||||
|
cd app-profile
|
||||||
|
./i2pconfig.sh
|
||||||
|
|
||||||
|
To generate a `deb` package, install the package `checkinstall` and run
|
||||||
|
the `make checkinstall` target after building with `make`.
|
||||||
|
|
||||||
|
make
|
||||||
|
make checkinstall
|
||||||
|
sudo apt install ./i2p-firefox*.deb
|
||||||
|
|
||||||
|
If you want to set up i2pconfig to run when you start the service
|
||||||
|
with `sudo service i2p start` then you can run the script:
|
||||||
|
|
||||||
|
/usr/local/bin/i2p-config-service-setup
|
||||||
|
|
||||||
|
Including a jpackaged I2P Router(EXPERIMENTAL)
|
||||||
|
----------------------------------------------
|
||||||
|
|
||||||
|
In order to include a jpackaged(dependency-free) I2P router in the Profile
|
||||||
|
Bundle you will need to build the jpackaged I2P router as an "App Image" on
|
||||||
|
a Windows system and place it into a directory called `I2P` in your `i2p.firefox`
|
||||||
|
checkout.
|
||||||
|
|
||||||
|
Assuming a working java and jpackage environment on your Windows system, the
|
||||||
|
following command should generate a suitable "App Image" in a directory
|
||||||
|
called "I2P."
|
||||||
|
|
||||||
|
export I2P_VERSION=0.9.49
|
||||||
|
cp -R ../i2p.i2p/pkg-temp/lib build/lib
|
||||||
|
jpackage --type app-image --name I2P --app-version "$I2P_VERSION" \
|
||||||
|
--verbose \
|
||||||
|
--resource-dir build/lib \
|
||||||
|
--input build/lib --main-jar router.jar --main-class net.i2p.router.RouterLaunch
|
||||||
|
|
||||||
|
Transfer the I2P directory to the machine where you build i2p.firefox if
|
||||||
|
necessary, then complete the regular build instructions. If a jpackaged I2P router
|
||||||
|
isn't present to use at build time, the inclusion will be skipped automatically
|
||||||
|
with a non-fatal warning.
|
||||||
|
|
||||||
|
In the near future, I'll start providing a pre-built app image to ease the
|
||||||
|
build process for non-Windows users.
|
||||||
|
|
||||||
|
End-to-End Windows build process using WSL
|
||||||
|
------------------------------------------
|
||||||
|
|
||||||
|
**If you've already done this once, you can just use:** `./build.sh && wsl make`
|
||||||
|
**in `git bash`** to automatically build an installer.
|
||||||
|
|
||||||
|
**Prerequisites:** You need to have OpenJDK 14 or greater installed and configured
|
||||||
|
with your `%JAVA_HOME%` environment variable configured and `%JAVA_HOME%/bin` on
|
||||||
|
your `%PATH%`. You need to have Apache Ant installed and configured with `%ANT_HOME%`
|
||||||
|
environment variable configured and `%ANT_HOME%/bin` on your `%PATH%`. You must have
|
||||||
|
Cygwin installed. You must have `NSIS.exe` installed and `makensis` available on your
|
||||||
|
`%PATH%`. You must have Git for Windows installed. When installing git for Windows,
|
||||||
|
you should select "Checkout as is, commit as is" and leave line-endings alone.
|
||||||
|
|
||||||
|
1. [Set up Windows Subsystem for Linux per Microsoft's instructions](https://docs.microsoft.com/en-us/windows/wsl/install-win10#manual-installation-steps)
|
||||||
|
2. [Install Ubuntu Focal per Microsoft's instructions](https://www.microsoft.com/store/apps/9n6svws3rx71)
|
||||||
|
3. Open Git Bash.
|
||||||
|
4. Install prerequisites `wsl sudo apt-get update && sudo apt-get install make nsis dos2unix curl jq`
|
||||||
|
5. Clone `i2p.i2p` and `i2p.firefox`
|
||||||
|
|
||||||
|
git clone https://github.com/i2p/i2p.i2p
|
||||||
|
git clone https://github.com/i2p/i2p.firefox
|
||||||
|
|
||||||
|
6. Move to the i2p.i2p directory. Build the .jar files required to build the App Image
|
||||||
|
inside i2p.i2p. Return to home.
|
||||||
|
|
||||||
|
cd i2p.i2p
|
||||||
|
ant clean pkg
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
7. Move into the i2p.firefox directory. Run the `./build.sh` script.
|
||||||
|
|
||||||
|
cd i2p.firefox
|
||||||
|
./build.sh
|
||||||
|
|
||||||
|
8. Compile the NSIS installer using WSL.
|
||||||
|
|
||||||
|
wsl make
|
||||||
|
|
||||||
|
End-to-End Windows build process using Cygwin
|
||||||
|
---------------------------------------------
|
||||||
|
|
||||||
|
**Prerequisites:** You need to have OpenJDK 14 or greater installed and configured
|
||||||
|
with your `%JAVA_HOME%` environment variable configured and `%JAVA_HOME%/bin` on
|
||||||
|
your `%PATH%`. You need to have Apache Ant installed and configured with `%ANT_HOME%`
|
||||||
|
environment variable configured and `%ANT_HOME%/bin` on your `%PATH%`. You must have
|
||||||
|
WSL and git bash installed. You must have `NSIS.exe` installed and `makensis` available on your
|
||||||
|
`%PATH%`. You must have Git for Windows installed. When installing git for Windows, you should
|
||||||
|
select "Checkout as is, commit as is" and leave line-endings alone.
|
||||||
|
|
||||||
|
TODO: Add links to the respective instructions for each of these.
|
||||||
|
|
||||||
|
1. Run the Cygwin `setup-$arch.exe` for your platform to set up new packages.
|
||||||
|
Select the `make` `jq` `dos2unix` and `curl` packages.
|
||||||
|
2. Open a cygwin terminal.
|
||||||
|
3. Clone `i2p.i2p` and `i2p.firefox`
|
||||||
|
|
||||||
|
git clone https://github.com/i2p/i2p.i2p
|
||||||
|
git clone https://github.com/i2p/i2p.firefox
|
||||||
|
|
||||||
|
3. Move to the i2p.i2p directory. Build the .jar files required to build the App Image
|
||||||
|
inside i2p.i2p. Return to home.
|
||||||
|
|
||||||
|
cd i2p.i2p
|
||||||
|
ant clean pkg
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
7. Move into the i2p.firefox directory. Run the `./build.sh` script.
|
||||||
|
|
||||||
|
cd i2p.firefox
|
||||||
|
./build.sh
|
||||||
|
|
||||||
|
5. Run `make` to build the installer.
|
||||||
|
|
||||||
|
Building a signed update file
|
||||||
|
-----------------------------
|
||||||
|
|
||||||
|
Building a signed update file for automatically updating a Windows I2P router
|
||||||
|
requires you to also have Go installed in your Cygwin or WSL environment.
|
||||||
|
With WSL, you can do this using the command:
|
||||||
|
|
||||||
|
wsl sudo apt-get install golang-go
|
||||||
|
|
||||||
|
With that dependency satisfied, you can then run:
|
||||||
|
|
||||||
|
wsl make su3
|
||||||
|
|
||||||
|
to build the signing tool if necessary and then package the installer in a
|
||||||
|
signed update file.
|
||||||
|
|
||||||
|
Docker Support
|
||||||
|
--------------
|
||||||
|
|
||||||
|
You can use a Docker container to install this browser profile as well. In order
|
||||||
|
to do this, you can run the commands:
|
||||||
|
|
||||||
|
xhost + local:docker
|
||||||
|
docker run -it --rm \
|
||||||
|
--net=host \
|
||||||
|
-e DISPLAY=unix$(DISPLAY) \
|
||||||
|
-v /tmp/.X11-unix:/tmp/.X11-unix \
|
||||||
|
geti2p/i2p.firefox firefox --profile /src/build/profile
|
||||||
|
|
||||||
|
To build and run the container locally, clone this repository and run the
|
||||||
|
|
||||||
|
make run
|
||||||
|
|
||||||
|
target.
|
||||||
|
|
||||||
|
Issues
|
||||||
|
------
|
||||||
|
|
||||||
|
To report issues against this browser profile, please file issues
|
||||||
|
at [the official Gitlab](https://i2pgit.org/i2p-hackers/i2p.firefox)
|
||||||
|
or the [Github Mirror](https://github.com/i2p/i2p.firefox). Issues
|
||||||
|
pertaining to the plugins may be reported to their upstream
|
||||||
|
maintainers if it's determined that our configuration is not at
|
||||||
|
fault.
|
||||||
|
|
||||||
|
NoScript is developed on Github by `hackademix` and the community:
|
||||||
|
- https://github.com/hackademix/noscript
|
||||||
|
|
||||||
|
HTTPS Everywhere is developed on Github by the EFF:
|
||||||
|
- https://github.com/EFForg/https-everywhere
|
||||||
|
|
||||||
|
I2P in Private Browsing is developed on Gitlab and Github by idk and the community:
|
||||||
|
- https://i2pgit.org/idk/I2P-in-Private-Browsing-Mode-Firefox
|
||||||
|
- https://github.com/eyedeekay/I2P-in-Private-Browsing-Mode-Firefox
|
||||||
|
|
||||||
|
|
||||||
29
UPDATES.md
Normal file
29
UPDATES.md
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
Setting up an Update Server for an I2P Bundle
|
||||||
|
=============================================
|
||||||
|
|
||||||
|
It is important to set up a signed update server so that people are able to
|
||||||
|
safely and anonymously update your I2P bundle.
|
||||||
|
|
||||||
|
The quick way:
|
||||||
|
--------------
|
||||||
|
|
||||||
|
This process depends on my ability to push releases to github. If you are
|
||||||
|
forking, setting up a dev server, or taking over because I got hit by a bus,
|
||||||
|
you'll need to do it the complete way.
|
||||||
|
|
||||||
|
For as long as I am building updates, you will be able to mirror the jpackaged
|
||||||
|
Windows bundle by cloning the repository `https://github.com/eyedeekay/i2p` and
|
||||||
|
running the `make docker run` target in that repository. You can retrieve the
|
||||||
|
base32 address of your update server by viewing the log with
|
||||||
|
`docker logs eephttpd-jpackage | grep b32.i2p | tee eephttpd-address.md`. To
|
||||||
|
update the site, run `./update.site.sh` in that repository.
|
||||||
|
|
||||||
|
Once you have cloned the repository and started the container with
|
||||||
|
`make docker run`, you can simply add `path/to/repo/update-site.sh` to your
|
||||||
|
`crontab` and it will update at an interval of your choosing.
|
||||||
|
|
||||||
|
The complete way:
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
TODO: describe how to do it with less of the awesome fancy stuff I put together
|
||||||
|
to make it easier on myself to keep an update server going.
|
||||||
4
amo-version.sh
Executable file
4
amo-version.sh
Executable file
@@ -0,0 +1,4 @@
|
|||||||
|
#! /usr/bin/env sh
|
||||||
|
|
||||||
|
curl -s "https://addons.mozilla.org/api/v5/addons/addon/$1/versions/?page_size=1" | jq '.results | .[0] | .version' | tr -d '"'
|
||||||
|
|
||||||
61
build.sh
Executable file
61
build.sh
Executable file
@@ -0,0 +1,61 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
. i2pversion
|
||||||
|
|
||||||
|
if [ -f i2pversion_override ]; then
|
||||||
|
. i2pversion_override
|
||||||
|
fi
|
||||||
|
|
||||||
|
JAVA=$(java --version | tr -d 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\n' | cut -d ' ' -f 2 | cut -d '.' -f 1 | tr -d '\n\t\- ')
|
||||||
|
|
||||||
|
if [ "$JAVA" -lt "14" ]; then
|
||||||
|
echo "Java 14+ must be used to compile with jpackage, java is $JAVA"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
sleep 2s
|
||||||
|
|
||||||
|
if [ -z "${JAVA_HOME}" ]; then
|
||||||
|
JAVA_HOME=`type -p java|xargs readlink -f|xargs dirname|xargs dirname`
|
||||||
|
echo "Building with: $JAVA, $JAVA_HOME"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "cleaning"
|
||||||
|
./clean.sh
|
||||||
|
|
||||||
|
HERE="$PWD"
|
||||||
|
cd "$HERE/../i2p.i2p/"
|
||||||
|
git checkout "$VERSION"
|
||||||
|
ant distclean preppkg-windows || true
|
||||||
|
|
||||||
|
cd "$HERE"
|
||||||
|
RES_DIR="$HERE/../i2p.i2p/installer/resources"
|
||||||
|
I2P_JARS="$HERE/../i2p.i2p/pkg-temp/lib"
|
||||||
|
I2P_JBIGI="$HERE/../i2p.i2p/installer/lib//jbigi"
|
||||||
|
I2P_PKG="$HERE/../i2p.i2p/pkg-temp"
|
||||||
|
|
||||||
|
echo "compiling custom launcher"
|
||||||
|
mkdir build
|
||||||
|
cp "$I2P_JARS"/*.jar build
|
||||||
|
|
||||||
|
cd java
|
||||||
|
"$JAVA_HOME"/bin/javac -d ../build -classpath "$HERE"/build/i2p.jar:"$HERE"/build/router.jar:"$HERE"/build/routerconsole.jar net/i2p/router/WinLauncher.java net/i2p/router/WindowsUpdatePostProcessor.java net/i2p/router/WinUpdateProcess.java
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
#echo "building launcher.jar"
|
||||||
|
cd build
|
||||||
|
"$JAVA_HOME"/bin/jar -cf launcher.jar net
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
if [ -z $I2P_VERSION ]; then
|
||||||
|
I2P_VERSION=$("$JAVA_HOME"/bin/java -cp build/router.jar net.i2p.router.RouterVersion | sed "s/.*: //" | head -n 1 | sed 's|-|.|g')
|
||||||
|
fi
|
||||||
|
echo "preparing to invoke jpackage for I2P version $I2P_VERSION"
|
||||||
|
|
||||||
|
|
||||||
|
"$JAVA_HOME"/bin/jpackage --type app-image --name I2P --app-version "$I2P_VERSION" \
|
||||||
|
--verbose \
|
||||||
|
$JPACKAGE_OPTS \
|
||||||
|
--resource-dir build \
|
||||||
|
--java-options "--illegal-access=permit" \
|
||||||
|
--input build --main-jar launcher.jar --main-class net.i2p.router.WinLauncher
|
||||||
@@ -1,8 +1,14 @@
|
|||||||
2020-12-20
|
2021-01-17 idk
|
||||||
|
* Use Local Application Data instead of Roaming application data for router.config file
|
||||||
|
* Use Roaming Application Daya only if a clients.config.d is present, indicating that the
|
||||||
|
roaming application directory is in use deliberately.
|
||||||
|
|
||||||
|
2020-12-20 idk
|
||||||
* Add I2P in Private Browsing plugin, which for the purposes of this profile provides
|
* Add I2P in Private Browsing plugin, which for the purposes of this profile provides
|
||||||
- X-I2P-Location functionality(Alternate service locations for mirrors)
|
- X-I2P-Location functionality(Alternate service locations for mirrors)
|
||||||
- X-I2P-TorrentLocation functionality(Alternate resource locations for sites)
|
- X-I2P-TorrentLocation functionality(Alternate resource locations for sites)
|
||||||
- Pre-Disable HTTPS only mode dom.security.https_only_mode=false in the profile in favor of HTTPS-Everywhere
|
- Pre-Disable HTTPS only mode dom.security.https_only_mode=false in the profile in favor of HTTPS-Everywhere
|
||||||
|
- Enable the use of extensions in private mode by default.
|
||||||
|
|
||||||
2019-02-10 zab
|
2019-02-10 zab
|
||||||
* Fix missing texts on Finish page
|
* Fix missing texts on Finish page
|
||||||
|
|||||||
17
clean.sh
Executable file
17
clean.sh
Executable file
@@ -0,0 +1,17 @@
|
|||||||
|
#! /usr/bin/env sh
|
||||||
|
|
||||||
|
rm -rf \
|
||||||
|
build \
|
||||||
|
eventlog.txt \
|
||||||
|
hostsdb.blockfile \
|
||||||
|
I2P \
|
||||||
|
i2p_1.0-1_amd64.deb \
|
||||||
|
libjbigi.so \
|
||||||
|
libjcpuid.so \
|
||||||
|
logs \
|
||||||
|
peerProfiles \
|
||||||
|
prngseed.rnd \
|
||||||
|
wrapper.log \
|
||||||
|
*.jar \
|
||||||
|
*.exe \
|
||||||
|
*.dmg
|
||||||
2
config.mk
Normal file
2
config.mk
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
SIGNER=hankhill19580@gmail.com
|
||||||
|
export SIGNER=hankhill19580@gmail.com
|
||||||
1
description-pak
Normal file
1
description-pak
Normal file
@@ -0,0 +1 @@
|
|||||||
|
A browser profile and accompanying script for launching it. Used to combine I2P with Firefox in a reasonably safe way.
|
||||||
@@ -1 +1 @@
|
|||||||
https://github.com/eyedeekay/I2P-in-Private-Browsing-Mode-Firefox/releases/download/0.79/i2ppb@eyedeekay.github.io.xpi
|
https://addons.mozilla.org/firefox/downloads/file/3784917/0.108/i2prhz@eyedeekay.github.io
|
||||||
|
|||||||
15
i2pversion
Normal file
15
i2pversion
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
#! /usr/bin/env sh
|
||||||
|
|
||||||
|
|
||||||
|
#Comment this out to build from an alternate branch or
|
||||||
|
# the tip of the master branch.
|
||||||
|
#I2P_VERSION=0.9.50
|
||||||
|
#export I2P_VERSION=0.9.50
|
||||||
|
#VERSION=i2p-$I2P_VERSION
|
||||||
|
#export VERSION="$VERSION"
|
||||||
|
|
||||||
|
#Uncomment this to build from the tip of the master.
|
||||||
|
I2P_VERSION=0.9.50
|
||||||
|
export I2P_VERSION=0.9.50
|
||||||
|
VERSION=master
|
||||||
|
export VERSION="$VERSION"
|
||||||
108
java/net/i2p/router/WinLauncher.java
Normal file
108
java/net/i2p/router/WinLauncher.java
Normal file
@@ -0,0 +1,108 @@
|
|||||||
|
package net.i2p.router;
|
||||||
|
|
||||||
|
import java.io.*;
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import net.i2p.crypto.*;
|
||||||
|
|
||||||
|
import net.i2p.app.ClientAppManager;
|
||||||
|
import net.i2p.router.RouterLaunch;
|
||||||
|
import net.i2p.router.Router;
|
||||||
|
import net.i2p.update.UpdateManager;
|
||||||
|
import net.i2p.update.UpdatePostProcessor;
|
||||||
|
import net.i2p.util.SystemVersion;
|
||||||
|
import net.i2p.update.*;
|
||||||
|
|
||||||
|
import static net.i2p.update.UpdateType.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Launches a router from %PROGRAMFILES%/I2P using configuration data in
|
||||||
|
* %LOCALAPPDATA%/I2P.. Uses Java 9 APIs.
|
||||||
|
|
||||||
|
* Sets the following properties:
|
||||||
|
* i2p.dir.base - this points to the (read-only) resources inside the bundle
|
||||||
|
* i2p.dir.config this points to the (read-write) config directory in local appdata
|
||||||
|
* router.pid - the pid of the java process.
|
||||||
|
*/
|
||||||
|
public class WinLauncher {
|
||||||
|
private static WindowsUpdatePostProcessor wupp = new WindowsUpdatePostProcessor();
|
||||||
|
public static void main(String[] args) throws Exception {
|
||||||
|
File programs = wupp.selectProgramFile();
|
||||||
|
if (!programs.exists())
|
||||||
|
programs.mkdirs();
|
||||||
|
else if (!programs.isDirectory()) {
|
||||||
|
System.err.println(programs + " exists but is not a directory. Please get it out of the way");
|
||||||
|
System.exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
File home = selectHome();
|
||||||
|
if (!home.exists())
|
||||||
|
home.mkdirs();
|
||||||
|
else if (!home.isDirectory()) {
|
||||||
|
System.err.println(home + " exists but is not a directory. Please get it out of the way");
|
||||||
|
System.exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
System.setProperty("i2p.dir.base", programs.getAbsolutePath());
|
||||||
|
System.setProperty("i2p.dir.config", home.getAbsolutePath());
|
||||||
|
System.setProperty("router.pid", String.valueOf(ProcessHandle.current().pid()));
|
||||||
|
System.out.println("\t"+System.getProperty("i2p.dir.base") +"\n\t"+System.getProperty("i2p.dir.config")+"\n\t"+ System.getProperty("router.pid"));
|
||||||
|
|
||||||
|
wupp.i2pRouter = new Router(System.getProperties());
|
||||||
|
System.out.println("Router is configured");
|
||||||
|
|
||||||
|
Thread registrationThread = new Thread(REGISTER_UPP);
|
||||||
|
registrationThread.setName("UPP Registration");
|
||||||
|
registrationThread.setDaemon(true);
|
||||||
|
registrationThread.start();
|
||||||
|
|
||||||
|
wupp.i2pRouter.runRouter();
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final Runnable REGISTER_UPP = () -> {
|
||||||
|
|
||||||
|
// first wait for the RouterContext to appear
|
||||||
|
RouterContext ctx;
|
||||||
|
while ((ctx = (RouterContext) wupp.i2pRouter.getContext().getCurrentContext()) == null) {
|
||||||
|
sleep(1000);
|
||||||
|
}
|
||||||
|
|
||||||
|
// then wait for the update manager
|
||||||
|
ClientAppManager cam = ctx.clientAppManager();
|
||||||
|
UpdateManager um;
|
||||||
|
while ((um = (UpdateManager) cam.getRegisteredApp(UpdateManager.APP_NAME)) == null) {
|
||||||
|
sleep(1000);
|
||||||
|
}
|
||||||
|
|
||||||
|
wupp = new WindowsUpdatePostProcessor(ctx);
|
||||||
|
um.register(wupp, UpdateType.ROUTER_SIGNED_SU3, SU3File.TYPE_EXE);
|
||||||
|
um.register(wupp, UpdateType.ROUTER_DEV_SU3, SU3File.TYPE_EXE);
|
||||||
|
};
|
||||||
|
|
||||||
|
private static void sleep(int millis) {
|
||||||
|
try {
|
||||||
|
Thread.sleep(millis);
|
||||||
|
} catch (InterruptedException bad) {
|
||||||
|
bad.printStackTrace();
|
||||||
|
throw new RuntimeException(bad);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static File selectHome() { //throws Exception {
|
||||||
|
if (SystemVersion.isWindows()) {
|
||||||
|
File home = new File(System.getProperty("user.home"));
|
||||||
|
File appData = new File(home, "AppData");
|
||||||
|
File local = new File(appData, "Local");
|
||||||
|
File i2p;
|
||||||
|
i2p = new File(local, "I2P");
|
||||||
|
System.out.println("Windows jpackage wrapper started, using: " + i2p + " as base config");
|
||||||
|
return i2p.getAbsoluteFile();
|
||||||
|
} else {
|
||||||
|
File jrehome = new File(System.getProperty("java.home"));
|
||||||
|
File programs = new File(jrehome.getParentFile().getParentFile(), ".i2p");
|
||||||
|
System.out.println("Linux portable jpackage wrapper started, using: " + programs + " as base config");
|
||||||
|
return programs.getAbsoluteFile();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
72
java/net/i2p/router/WinUpdateProcess.java
Normal file
72
java/net/i2p/router/WinUpdateProcess.java
Normal file
@@ -0,0 +1,72 @@
|
|||||||
|
package net.i2p.router;
|
||||||
|
|
||||||
|
import net.i2p.router.*;
|
||||||
|
import net.i2p.I2PAppContext;
|
||||||
|
|
||||||
|
import java.util.function.*;
|
||||||
|
import java.io.*;
|
||||||
|
import net.i2p.util.Log;
|
||||||
|
|
||||||
|
class WinUpdateProcess implements Runnable {
|
||||||
|
private final RouterContext ctx;
|
||||||
|
private final Supplier<String> versionSupplier;
|
||||||
|
private final Supplier<File> fileSupplier;
|
||||||
|
|
||||||
|
WinUpdateProcess(RouterContext ctx, Supplier<String> versionSupplier, Supplier<File> fileSupplier) {
|
||||||
|
this.ctx = ctx;
|
||||||
|
this.versionSupplier = versionSupplier;
|
||||||
|
this.fileSupplier = fileSupplier;
|
||||||
|
}
|
||||||
|
|
||||||
|
private File workDir() throws IOException{
|
||||||
|
if (ctx != null) {
|
||||||
|
File workDir = new File(ctx.getConfigDir().getAbsolutePath(), "i2p_update_win");
|
||||||
|
if (workDir.exists()) {
|
||||||
|
if (workDir.isFile())
|
||||||
|
throw new IOException(workDir + " exists but is a file, get it out of the way");
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
workDir.mkdirs();
|
||||||
|
}
|
||||||
|
return workDir;
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void runUpdateInstaller() throws IOException {
|
||||||
|
String version = versionSupplier.get();
|
||||||
|
File file = fileSupplier.get();
|
||||||
|
if (file == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
var workingDir = workDir();
|
||||||
|
var logFile = new File(workingDir, "log-" + version + ".txt");
|
||||||
|
|
||||||
|
ProcessBuilder pb = new ProcessBuilder(file.getAbsolutePath());
|
||||||
|
var env = pb.environment();
|
||||||
|
env.put("OLD_I2P_VERSION", version);
|
||||||
|
env.remove("RESTART_I2P");
|
||||||
|
|
||||||
|
int exitCode = ctx.router().scheduledGracefulExitCode();
|
||||||
|
if (exitCode == Router.EXIT_HARD_RESTART || exitCode == Router.EXIT_GRACEFUL_RESTART)
|
||||||
|
env.put("RESTART_I2P", "true");
|
||||||
|
|
||||||
|
try {
|
||||||
|
pb.directory(workingDir).
|
||||||
|
redirectErrorStream(true).
|
||||||
|
redirectOutput(logFile).
|
||||||
|
start();
|
||||||
|
} catch (IOException ex) {
|
||||||
|
System.out.println("Unable to run update-program in background. Update will fail.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
try {
|
||||||
|
runUpdateInstaller();
|
||||||
|
} catch(IOException ioe) {
|
||||||
|
System.out.println("Error running updater, update may fail." + ioe);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
119
java/net/i2p/router/WindowsUpdatePostProcessor.java
Normal file
119
java/net/i2p/router/WindowsUpdatePostProcessor.java
Normal file
@@ -0,0 +1,119 @@
|
|||||||
|
package net.i2p.router;
|
||||||
|
|
||||||
|
import java.io.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.util.concurrent.TimeUnit;
|
||||||
|
import java.util.concurrent.atomic.*;
|
||||||
|
|
||||||
|
|
||||||
|
import net.i2p.crypto.*;
|
||||||
|
import static net.i2p.update.UpdateType.*;
|
||||||
|
import net.i2p.I2PAppContext;
|
||||||
|
import net.i2p.update.UpdateType;
|
||||||
|
import net.i2p.update.UpdatePostProcessor;
|
||||||
|
import net.i2p.util.Log;
|
||||||
|
import net.i2p.util.SystemVersion;
|
||||||
|
|
||||||
|
import java.lang.ProcessBuilder;
|
||||||
|
import java.lang.Process;
|
||||||
|
import java.lang.InterruptedException;
|
||||||
|
|
||||||
|
|
||||||
|
public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
|
||||||
|
private final Log _log = I2PAppContext.getGlobalContext().logManager().getLog(WindowsUpdatePostProcessor.class);
|
||||||
|
private final RouterContext ctx;
|
||||||
|
protected static Router i2pRouter = null;
|
||||||
|
|
||||||
|
private final AtomicBoolean hook = new AtomicBoolean();
|
||||||
|
|
||||||
|
private volatile String version;
|
||||||
|
|
||||||
|
private volatile File positionedFile = null;
|
||||||
|
private final String fileName = "i2p-jpackage-update.exe";
|
||||||
|
|
||||||
|
WindowsUpdatePostProcessor() {
|
||||||
|
this.ctx = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
WindowsUpdatePostProcessor(RouterContext ctx) {
|
||||||
|
this.ctx = ctx;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getVersion() {
|
||||||
|
return version;
|
||||||
|
}
|
||||||
|
|
||||||
|
public File getFile() {
|
||||||
|
return positionedFile;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void updateDownloadedandVerified(UpdateType type, int fileType, String version, File file) throws IOException {
|
||||||
|
_log.info("Got an update to post-process");
|
||||||
|
|
||||||
|
if (type != UpdateType.ROUTER_SIGNED_SU3 && type != UpdateType.ROUTER_DEV_SU3) {
|
||||||
|
_log.warn("Unsupported update type " + type);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (fileType != SU3File.TYPE_EXE) {
|
||||||
|
_log.warn("Unsupported file type " + fileType);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
this.positionedFile = moveUpdateInstaller(file);
|
||||||
|
this.version = version;
|
||||||
|
|
||||||
|
if (!hook.compareAndSet(false,true)) {
|
||||||
|
_log.info("shutdown hook was already set");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
_log.info("adding shutdown hook");
|
||||||
|
ctx.addFinalShutdownTask(new WinUpdateProcess(ctx, this::getVersion, this::getFile));
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private File moveUpdateInstaller(File file) throws IOException {
|
||||||
|
RouterContext i2pContext = i2pRouter.getContext();
|
||||||
|
if (i2pContext != null) {
|
||||||
|
File newFile = new File(workDir(), fileName);
|
||||||
|
boolean renamedStatus = file.renameTo(newFile);
|
||||||
|
if (renamedStatus)
|
||||||
|
return newFile;
|
||||||
|
else
|
||||||
|
throw new IOException("WindowsUpdatePostProcesssor unable to move file to working directory, update will fail");
|
||||||
|
}
|
||||||
|
throw new IOException("Router context not available to WindowsUpdatePostProcesssor, unable to find working directory, update will fail");
|
||||||
|
}
|
||||||
|
|
||||||
|
private File workDir() throws IOException{
|
||||||
|
RouterContext i2pContext = i2pRouter.getContext();
|
||||||
|
if (i2pContext != null) {
|
||||||
|
File workDir = new File(i2pContext.getConfigDir().getAbsolutePath(), "i2p_update_win");
|
||||||
|
if (workDir.exists()) {
|
||||||
|
if (workDir.isFile())
|
||||||
|
throw new IOException(workDir + " exists but is a file, get it out of the way");
|
||||||
|
return null;
|
||||||
|
} else {
|
||||||
|
workDir.mkdirs();
|
||||||
|
}
|
||||||
|
return workDir;
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected File selectProgramFile() {
|
||||||
|
if (SystemVersion.isWindows()) {
|
||||||
|
File jrehome = new File(System.getProperty("java.home"));
|
||||||
|
File programs = jrehome.getParentFile();
|
||||||
|
System.out.println("Windows portable jpackage wrapper found, using: " + programs + " as working config");
|
||||||
|
return programs.getAbsoluteFile();
|
||||||
|
} else {
|
||||||
|
File jrehome = new File(System.getProperty("java.home"));
|
||||||
|
File programs = new File(jrehome.getParentFile().getParentFile(), "i2p");
|
||||||
|
System.out.println("Linux portable jpackage wrapper found, using: " + programs + " as working config");
|
||||||
|
return programs.getAbsoluteFile();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
21
license/i2ppb.txt
Normal file
21
license/i2ppb.txt
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2019 idk
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in all
|
||||||
|
copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.
|
||||||
3
router.config
Normal file
3
router.config
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
router.updateURL=http://ekm3fu6fr5pxudhwjmdiea5dovc3jdi66hjgop4c7z7dfaw7spca.b32.i2p/i2pwinupdate.su3
|
||||||
|
router.newsURL=http://tc73n4kivdroccekirco7rhgxdg5f3cjvbaapabupeyzrqwv5guq.b32.i2p/win/stable/news.su3
|
||||||
|
router.backupNewsURL=http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news/win/stable/news.su3
|
||||||
19
src/app-profile/bookmarks.html
Normal file
19
src/app-profile/bookmarks.html
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
<!DOCTYPE NETSCAPE-Bookmark-file-1>
|
||||||
|
<!-- This is an automatically generated file.
|
||||||
|
It will be read and overwritten.
|
||||||
|
DO NOT EDIT! -->
|
||||||
|
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
|
||||||
|
<TITLE>Bookmarks</TITLE>
|
||||||
|
<H1>Bookmarks Menu</H1>
|
||||||
|
|
||||||
|
<DL><p>
|
||||||
|
<DT><A HREF="place:type=6&sort=14&maxResults=10" ADD_DATE="1539649423" LAST_MODIFIED="1539649424">Recent Tags</A>
|
||||||
|
<HR> <DT><A HREF="http://legwork.i2p/yacysearch.html?query=%s&verify=cacheonly&contentdom=text&nav=location%2Chosts%2Cauthors%2Cnamespace%2Ctopics%2Cfiletype%2Cprotocol%2Clanguage&startRecord=0&indexof=off&meanCount=5&resource=global&prefermaskfilter=&maximumRecords=10&timezoneOffset=0" ADD_DATE="1539652098" LAST_MODIFIED="1539652098" SHORTCUTURL="legwork.i2p">Search YaCy 'legwork': Search Page</A>
|
||||||
|
<DD>Software HTTP Freeware Home Page
|
||||||
|
<DT><H3 ADD_DATE="1539649419" LAST_MODIFIED="1539649423" PERSONAL_TOOLBAR_FOLDER="true">Bookmarks Toolbar</H3>
|
||||||
|
<DL><p>
|
||||||
|
<DT><A HREF="place:sort=8&maxResults=10" ADD_DATE="1539649423" LAST_MODIFIED="1539649423">Most Visited</A>
|
||||||
|
<DT><A HREF="http://i2p-projekt.i2p/" ADD_DATE="1538511080" LAST_MODIFIED="1538511080">I2P Anonymous Network</A>
|
||||||
|
<DD>Anonymous peer-to-peer distributed communication layer built with open source tools and designed to run any traditional Internet service such as email, IRC or web hosting.
|
||||||
|
</DL><p>
|
||||||
|
</DL>
|
||||||
26
src/app-profile/chrome/userChrome.css
Normal file
26
src/app-profile/chrome/userChrome.css
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
|
||||||
|
@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /* only needed once */
|
||||||
|
@namespace html url("http://www.w3.org/1999/xhtml");
|
||||||
|
|
||||||
|
#PersonalToolbar, #PanelUI-Button, #PanelUI-menu-button, #star-button, #forward-button, #home-button, #bookmarks-toolbar-button, #library-button, #sidebar-button, #pocket-button, #fxa-toolbar-menu-button, #reader-mode-button, #identity-icon {
|
||||||
|
visibility: collapse;
|
||||||
|
}
|
||||||
|
|
||||||
|
#urlbar-background {background-color: black !important;}
|
||||||
|
|
||||||
|
/* Remove back button circle */
|
||||||
|
#back-button:not(:hover),
|
||||||
|
#back-button:not(:hover) > .toolbarbutton-icon {
|
||||||
|
background: transparent !important;
|
||||||
|
border: none !important;
|
||||||
|
box-shadow: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
#back-button:hover,
|
||||||
|
#back-button:hover > .toolbarbutton-icon {
|
||||||
|
border: none !important;
|
||||||
|
border-radius: 2px !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
#urlbar-container, #nav-bar { visibility: collapse !important }
|
||||||
|
}
|
||||||
62
src/app-profile/prefs.js
Normal file
62
src/app-profile/prefs.js
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
user_pref("extensions.https_everywhere._observatory.enabled", false);
|
||||||
|
user_pref("extensions.https_everywhere.options.autoUpdateRulesets", false);
|
||||||
|
user_pref("extensions.https_everywhere.globalEnabled", false);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.submit_during_tor", false);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.submit_during_nontor", false);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.use_custom_proxy", true);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.proxy_host", "127.0.0.1");
|
||||||
|
user_pref("extensions.https_everywhere._observatory.proxy_port", 4444);
|
||||||
|
|
||||||
|
user_pref("extensions.torbutton.use_nontor_proxy", true);
|
||||||
|
|
||||||
|
//For socket conversion: in the future, I'll need to make TBB communicate with
|
||||||
|
//i2p over a unix socket. Fortunately, this is how you do that. It will be
|
||||||
|
//configurable in a similar way to the host:port configuration when that happens.
|
||||||
|
//user_pref("extensions.torlauncher.socks_port_use_ipc", );
|
||||||
|
//user_pref("extensions.torlauncher.socks_ipc_path", "");
|
||||||
|
|
||||||
|
user_pref("extensions.torlauncher.start_tor", false);
|
||||||
|
//user_pref("extensions.torlauncher.default_bridge_type", "");
|
||||||
|
user_pref("extensions.torlauncher.prompt_at_startup", false);
|
||||||
|
|
||||||
|
// Resist-fingerprinting and first-party isolation enable
|
||||||
|
|
||||||
|
user_pref("privacy.resistFingerprinting", true);
|
||||||
|
user_pref("privacy.firstparty.isolate", true);
|
||||||
|
|
||||||
|
// Use i2p http proxy for all connections and set homepage to safe local form.
|
||||||
|
|
||||||
|
// DON'T allow access to the admin panel from the profile we browse i2p with.
|
||||||
|
user_pref("network.proxy.no_proxies_on", "127.0.0.1:7657,localhost:7657,127.0.0.1:7662,localhost:7662,127.0.0.1:7669,localhost:7669");
|
||||||
|
user_pref("network.proxy.type", 1);
|
||||||
|
user_pref("network.proxy.http", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.http_port", 4444);
|
||||||
|
user_pref("network.proxy.ssl", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.ssl_port", 4444);
|
||||||
|
user_pref("network.proxy.ftp", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.ftp_port", 4444);
|
||||||
|
user_pref("network.proxy.socks", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.socks_port", 4444);
|
||||||
|
user_pref("network.proxy.share_proxy_settings", true);
|
||||||
|
user_pref("browser.startup.homepage", "about:blank");
|
||||||
|
user_pref("dom.security.https_only_mode", false);
|
||||||
|
user_pref("keyword.enabled", false);
|
||||||
|
user_pref("extensions.allowPrivateBrowsingByDefault", true);
|
||||||
|
user_pref("extensions.PrivateBrowsing.notification", false);
|
||||||
|
|
||||||
|
user_pref("toolkit.legacyUserProfileCustomizations.stylesheets", true);
|
||||||
|
user_pref("extensions.pocket.enabled", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSponsoredTopSites", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("services.sync.prefs.sync.browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.section.highlights", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.section.topstories", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.default.sites", "http://127.0.0.1:7657/home,http://127.0.0.1:7657/i2psnark/,http://127.0.0.1:7657/susimail/");
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.topsites", true);
|
||||||
|
user_pref("ui.use_standins_for_native_colors", true);
|
||||||
|
user_pref("webgl.disable-extensions", true);
|
||||||
|
user_pref("webgl.min_capability_mode", true);
|
||||||
|
user_pref("webgl.disable-fail-if-major-performance-caveat", true);
|
||||||
|
user_pref("webgl.enable-webgl2", false);
|
||||||
|
user_pref("media.navigator.enabled", false);
|
||||||
|
user_pref("dom.w3c_touch_events.enabled", false);
|
||||||
BIN
src/app-profile/storage-sync.sqlite
Executable file
BIN
src/app-profile/storage-sync.sqlite
Executable file
Binary file not shown.
224
src/app-profile/user.js
Normal file
224
src/app-profile/user.js
Normal file
@@ -0,0 +1,224 @@
|
|||||||
|
# Overrides for Extension Preferences
|
||||||
|
# Tor Browser Bundle
|
||||||
|
# Do not edit this file.
|
||||||
|
#
|
||||||
|
# This file is modified from a file included in the Tor Browser Bundle.
|
||||||
|
#
|
||||||
|
# Copyright 2017 The Tor Project. See LICENSE.tor for licensing information.
|
||||||
|
|
||||||
|
# HTTPS Everywhere Preferences:
|
||||||
|
user_pref("extensions.https_everywhere._observatory.popup_shown", true);
|
||||||
|
user_pref("extensions.https_everywhere.toolbar_hint_shown", true);
|
||||||
|
|
||||||
|
# NoScript Preferences:
|
||||||
|
# In order to disable all scripts by default, uncomment the following line...
|
||||||
|
# user_pref("capability.policy.maonoscript.javascript.enabled", "noAccess");
|
||||||
|
# and comment out the following line
|
||||||
|
user_pref("capability.policy.maonoscript.javascript.enabled", "allAccess");
|
||||||
|
user_pref("capability.policy.maonoscript.sites", "[System+Principal] about: about:tbupdate about:tor chrome: resource: blob: mediasource: moz-extension: moz-safe-about: about:neterror about:certerror about:feeds about:tabcrashed about:cache");
|
||||||
|
user_pref("noscript.default", "[System+Principal] about: about:tbupdate about:tor chrome: resource: blob: mediasource: moz-extension: moz-safe-about: about:neterror about:certerror about:feeds about:tabcrashed about:cache");
|
||||||
|
user_pref("noscript.mandatory", "[System+Principal] about: about:tbupdate about:tor chrome: resource: blob: mediasource: moz-extension: moz-safe-about: about:neterror about:certerror about:feeds about:tabcrashed about:cache");
|
||||||
|
user_pref("noscript.ABE.enabled", false);
|
||||||
|
user_pref("noscript.ABE.notify", false);
|
||||||
|
user_pref("noscript.ABE.wanIpAsLocal", false);
|
||||||
|
user_pref("noscript.confirmUnblock", false);
|
||||||
|
user_pref("noscript.contentBlocker", true);
|
||||||
|
user_pref("noscript.firstRunRedirection", false);
|
||||||
|
user_pref("noscript.global", true);
|
||||||
|
user_pref("noscript.gtemp", "");
|
||||||
|
user_pref("noscript.opacizeObject", 3);
|
||||||
|
user_pref("noscript.forbidWebGL", true);
|
||||||
|
user_pref("noscript.forbidFonts", true);
|
||||||
|
user_pref("noscript.options.tabSelectedIndexes", "5,0,0");
|
||||||
|
user_pref("noscript.policynames", "");
|
||||||
|
user_pref("noscript.secureCookies", true);
|
||||||
|
user_pref("noscript.showAllowPage", false);
|
||||||
|
user_pref("noscript.showBaseDomain", false);
|
||||||
|
user_pref("noscript.showDistrust", false);
|
||||||
|
user_pref("noscript.showRecentlyBlocked", false);
|
||||||
|
user_pref("noscript.showTemp", false);
|
||||||
|
user_pref("noscript.showTempToPerm", false);
|
||||||
|
user_pref("noscript.showUntrusted", false);
|
||||||
|
user_pref("noscript.STS.enabled", false);
|
||||||
|
user_pref("noscript.subscription.lastCheck", -142148139);
|
||||||
|
user_pref("noscript.temp", "");
|
||||||
|
user_pref("noscript.untrusted", "");
|
||||||
|
user_pref("noscript.forbidMedia", true);
|
||||||
|
user_pref("noscript.allowWhitelistUpdates", false);
|
||||||
|
user_pref("noscript.fixLinks", false);
|
||||||
|
// Now handled by plugins.click_to_play // Not in this one.
|
||||||
|
user_pref("noscript.forbidFlash", true);
|
||||||
|
user_pref("noscript.forbidSilverlight", true);
|
||||||
|
user_pref("noscript.forbidJava", true);
|
||||||
|
user_pref("noscript.forbidPlugins", true);
|
||||||
|
// Usability tweaks
|
||||||
|
user_pref("noscript.showPermanent", false);
|
||||||
|
user_pref("noscript.showTempAllowPage", true);
|
||||||
|
user_pref("noscript.showRevokeTemp", true);
|
||||||
|
user_pref("noscript.notify", false);
|
||||||
|
user_pref("noscript.autoReload", true);
|
||||||
|
user_pref("noscript.autoReload.allTabs", false);
|
||||||
|
user_pref("noscript.cascadePermissions", true);
|
||||||
|
user_pref("noscript.restrictSubdocScripting", true);
|
||||||
|
user_pref("noscript.showVolatilePrivatePermissionsToggle", false);
|
||||||
|
user_pref("noscript.volatilePrivatePermissions", true);
|
||||||
|
user_pref("noscript.clearClick", 0);
|
||||||
|
|
||||||
|
user_pref("intl.locale.matchOS", false);
|
||||||
|
|
||||||
|
user_pref("extensions.https_everywhere._observatory.enabled", false);
|
||||||
|
user_pref("extensions.https_everywhere.options.autoUpdateRulesets", false);
|
||||||
|
user_pref("extensions.https_everywhere.globalEnabled", false);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.submit_during_tor", false);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.submit_during_nontor", false);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.use_custom_proxy", true);
|
||||||
|
user_pref("extensions.https_everywhere._observatory.proxy_host", "127.0.0.1");
|
||||||
|
user_pref("extensions.https_everywhere._observatory.proxy_port", 4444);
|
||||||
|
|
||||||
|
user_pref("extensions.torbutton.use_nontor_proxy", true);
|
||||||
|
|
||||||
|
//For socket conversion: in the future, I'll need to make TBB communicate with
|
||||||
|
//i2p over a unix socket. Fortunately, this is how you do that. It will be
|
||||||
|
//configurable in a similar way to the host:port configuration when that happens.
|
||||||
|
//user_pref("extensions.torlauncher.socks_port_use_ipc", );
|
||||||
|
//user_pref("extensions.torlauncher.socks_ipc_path", "");
|
||||||
|
|
||||||
|
user_pref("extensions.torlauncher.start_tor", false);
|
||||||
|
//user_pref("extensions.torlauncher.default_bridge_type", "");
|
||||||
|
user_pref("extensions.torlauncher.prompt_at_startup", false);
|
||||||
|
|
||||||
|
// Resist-fingerprinting and first-party isolation enable
|
||||||
|
|
||||||
|
user_pref("privacy.resistFingerprinting", true);
|
||||||
|
user_pref("privacy.firstparty.isolate", true);
|
||||||
|
|
||||||
|
// Use i2p http proxy for all connections and set homepage to safe local form.
|
||||||
|
|
||||||
|
// DON'T allow access to the admin panel from the profile we browse i2p with.
|
||||||
|
user_pref("network.proxy.no_proxies_on", "127.0.0.1:7657,localhost:7657,127.0.0.1:7662,localhost:7662,127.0.0.1:7669,localhost:7669");
|
||||||
|
user_pref("network.proxy.type", 1);
|
||||||
|
user_pref("network.proxy.http", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.http_port", 4444);
|
||||||
|
user_pref("network.proxy.ssl", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.ssl_port", 4444);
|
||||||
|
user_pref("network.proxy.ftp", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.ftp_port", 4444);
|
||||||
|
user_pref("network.proxy.socks", "127.0.0.1");
|
||||||
|
user_pref("network.proxy.socks_port", 4444);
|
||||||
|
user_pref("network.proxy.share_proxy_settings", true);
|
||||||
|
user_pref("browser.startup.homepage", "about:blank");
|
||||||
|
|
||||||
|
// Privacy-harden and disable irrelevant features.
|
||||||
|
user_pref("app.normandy.api_url", "");
|
||||||
|
user_pref("app.normandy.enabled", false);
|
||||||
|
user_pref("app.update.auto", false);
|
||||||
|
user_pref("app.update.enabled", false);
|
||||||
|
user_pref("beacon.enabled", false);
|
||||||
|
user_pref("browser.aboutHomeSnippets.updateUrl", "");
|
||||||
|
user_pref("browser.cache.disk_cache_ssl", false);
|
||||||
|
user_pref("browser.cache.disk.enable", false);
|
||||||
|
user_pref("browser.cache.offline.enable", false);
|
||||||
|
user_pref("browser.disableResetPrompt", true);
|
||||||
|
user_pref("browser.display.use_document_fonts", 0);
|
||||||
|
user_pref("browser.fixup.alternate.enabled", false);
|
||||||
|
user_pref("browser.formfill.enable", false);
|
||||||
|
user_pref("browser.library.activity-stream.enabled", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.disableSnippets", true);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.enabled", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.section.highlights", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.snippets", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.telemetry", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.topsites", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.prerender", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSearch", false);
|
||||||
|
user_pref("browser.newtabpage.enhanced", false);
|
||||||
|
user_pref("browser.newtabpage.introShown", true);
|
||||||
|
user_pref("browser.newtab.preload", false);
|
||||||
|
user_pref("browser.onboarding.enabled", false);
|
||||||
|
user_pref("browser.pagethumbnails.capturing_disabled", true);
|
||||||
|
user_pref("browser.safebrowsing.appRepURL", "");
|
||||||
|
user_pref("browser.safebrowsing.blockedURIs.enabled", false);
|
||||||
|
user_pref("browser.safebrowsing.downloads.enabled", false);
|
||||||
|
user_pref("browser.safebrowsing.downloads.remote.enabled", false);
|
||||||
|
user_pref("browser.safebrowsing.downloads.remote.url", "");
|
||||||
|
user_pref("browser.safebrowsing.enabled", false);
|
||||||
|
user_pref("browser.safebrowsing.malware.enabled", false);
|
||||||
|
user_pref("browser.safebrowsing.phishing.enabled", false);
|
||||||
|
user_pref("browser.search.geoip.timeout", 1);
|
||||||
|
user_pref("browser.search.suggest.enabled", false);
|
||||||
|
user_pref("browser.selfsupport.url", "");
|
||||||
|
user_pref("browser.send_pings", false);
|
||||||
|
user_pref("browser.shell.checkDefaultBrowser", false);
|
||||||
|
user_pref("browser.startup.homepage_override.mstone", "ignore");
|
||||||
|
user_pref("browser.startup.page", 0);
|
||||||
|
user_pref("browser.toolbarbuttons.introduced.pocket-button", true);
|
||||||
|
user_pref("browser.urlbar.speculativeConnect.enabled", false);
|
||||||
|
user_pref("browser.urlbar.trimURLs", false);
|
||||||
|
user_pref("datareporting.healthreport.uploadEnabled", false);
|
||||||
|
user_pref("datareporting.policy.dataSubmissionEnabled", false);
|
||||||
|
user_pref("dom.battery.enabled", false);
|
||||||
|
user_pref("dom.enable_performance", false);
|
||||||
|
user_pref("dom.enable_performance_navigation_timing", false);
|
||||||
|
user_pref("dom.enable_resource_timing", false);
|
||||||
|
user_pref("dom.event.clipboardevents.enabled", false);
|
||||||
|
user_pref("dom.gamepad.enabled", false);
|
||||||
|
user_pref("dom.indexedDB.enabled", false);
|
||||||
|
user_pref("dom.min_timeout_value", 400);
|
||||||
|
user_pref("dom.push.connection.enabled", false);
|
||||||
|
user_pref("dom.push.enabled", false);
|
||||||
|
user_pref("dom.serviceWorkers.enabled", false);
|
||||||
|
user_pref("dom.serviceWorkers.interception.enabled", false);
|
||||||
|
user_pref("dom.storage.enabled", false);
|
||||||
|
user_pref("dom.webaudio.enabled", false);
|
||||||
|
user_pref("extensions.autoDisableScopes", 14);
|
||||||
|
user_pref("extensions.getAddons.cache.enabled", false);
|
||||||
|
user_pref("extensions.getAddons.showPane", false);
|
||||||
|
user_pref("extensions.pocket.enabled", false);
|
||||||
|
user_pref("extensions.screenshots.disabled", true);
|
||||||
|
user_pref("extensions.webservice.discoverURL", "");
|
||||||
|
user_pref("geo.enabled", false);
|
||||||
|
user_pref("geo.wifi.uri", "");
|
||||||
|
user_pref("gfx.downloadable_fonts.disable_cache", true);
|
||||||
|
user_pref("javascript.options.shared_memory", false);
|
||||||
|
user_pref("layout.css.visited_links_enabled", false);
|
||||||
|
user_pref("media.autoplay.enabled", false);
|
||||||
|
user_pref("media.cache_size", 0);
|
||||||
|
user_pref("media.navigator.enabled", false);
|
||||||
|
user_pref("media.peerconnection.enabled", false);
|
||||||
|
user_pref("media.video_stats.enabled", false);
|
||||||
|
user_pref("captivedetect.canonicalURL", "");
|
||||||
|
user_pref("network.captive-portal-service.enabled", false);
|
||||||
|
user_pref("network.cookie.cookieBehavior", 1);
|
||||||
|
user_pref("network.cookie.lifetimePolicy", 2);
|
||||||
|
user_pref("network.dns.disablePrefetch", true);
|
||||||
|
user_pref("network.http.referer.spoofSource", true);
|
||||||
|
user_pref("network.http.referer.trimmingPolicy", 2);
|
||||||
|
user_pref("network.http.referer.XOriginPolicy", 2);
|
||||||
|
user_pref("network.prefetch-next", false);
|
||||||
|
user_pref("privacy.donottrackheader.enabled", true);
|
||||||
|
user_pref("privacy.donottrackheader.value", 1);
|
||||||
|
user_pref("toolkit.telemetry.archive.enabled", false);
|
||||||
|
user_pref("toolkit.telemetry.coverage.opt-out", true);
|
||||||
|
user_pref("toolkit.telemetry.enabled", false);
|
||||||
|
user_pref("toolkit.telemetry.server", "");
|
||||||
|
user_pref("toolkit.telemetry.unified", false);
|
||||||
|
user_pref("webgl.disabled", true);
|
||||||
|
user_pref("browser.chrome.errorReporter.infoURL", "");
|
||||||
|
user_pref("breakpad.reportURL", "");
|
||||||
|
//user_pref("browser.newtabpage.activity-stream.default.sites", "");
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSponsoredTopSites", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("services.sync.prefs.sync.browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("browser.newtabpage.enabled", true);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.default.sites", "http://127.0.0.1:7657/home,http://127.0.0.1:7657/i2psnark/,http://127.0.0.1:7657/susimail/");
|
||||||
|
user_pref("dom.security.https_only_mode", false);
|
||||||
|
user_pref("keyword.enabled", false);
|
||||||
|
user_pref("extensions.allowPrivateBrowsingByDefault", true);
|
||||||
|
user_pref("extensions.PrivateBrowsing.notification", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.topsites", true);
|
||||||
|
user_pref("ui.use_standins_for_native_colors", true);
|
||||||
|
user_pref("webgl.disable-extensions", true);
|
||||||
|
user_pref("webgl.min_capability_mode", true);
|
||||||
|
user_pref("webgl.disable-fail-if-major-performance-caveat", true);
|
||||||
|
user_pref("webgl.enable-webgl2", false);
|
||||||
|
user_pref("dom.w3c_touch_events.enabled", false);
|
||||||
1
src/app-profile/version.txt
Normal file
1
src/app-profile/version.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
0.04.0
|
||||||
122
src/nsis/FindProcess.nsh
Normal file
122
src/nsis/FindProcess.nsh
Normal file
@@ -0,0 +1,122 @@
|
|||||||
|
/* FindProcess.nsh
|
||||||
|
*
|
||||||
|
* written by Donald Miller
|
||||||
|
* Mar 7, 2007
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
!include LogicLib.nsh
|
||||||
|
!include WordFunc.nsh
|
||||||
|
!insertmacro WordFind
|
||||||
|
|
||||||
|
!ifndef FindProcess
|
||||||
|
!define FindProcess '!insertmacro FindProcess'
|
||||||
|
|
||||||
|
!macro FindProcess ProcessList BoolReturn
|
||||||
|
Push '${ProcessList}'
|
||||||
|
Call FindProcess
|
||||||
|
Pop ${BoolReturn}
|
||||||
|
!macroend
|
||||||
|
|
||||||
|
Function FindProcess
|
||||||
|
# return True if any process in ProcessList is active
|
||||||
|
Exch $0 ; get ProcessList, save $0
|
||||||
|
Push $1
|
||||||
|
Push $2
|
||||||
|
Push $R0
|
||||||
|
Push $R1
|
||||||
|
Push $R2
|
||||||
|
|
||||||
|
StrCpy $2 "$0," ; $2 = ProcessList
|
||||||
|
|
||||||
|
Push 0 ; set return value = False
|
||||||
|
|
||||||
|
# method based upon one by Phoenix1701@gmail.com 1/27/07
|
||||||
|
|
||||||
|
System::Alloc 1024
|
||||||
|
Pop $R0 ; process list buffer
|
||||||
|
|
||||||
|
# get an array of all process ids
|
||||||
|
System::Call "Psapi::EnumProcesses(i R0, i 1024, *i .R1)i .r0"
|
||||||
|
${Unless} $0 = 0
|
||||||
|
|
||||||
|
IntOp $R1 $R1 / 4 ; Divide by sizeof(DWORD) to get $R1 process count
|
||||||
|
IntOp $R1 $R1 - 1 ; decr for 0 base loop
|
||||||
|
|
||||||
|
ClearErrors
|
||||||
|
${For} $R2 0 $R1
|
||||||
|
# get a PID from the array
|
||||||
|
IntOp $0 $R2 << 2
|
||||||
|
IntOp $0 $0 + $R0 ; buffer.dword[i]
|
||||||
|
System::Call "*$0(i .r0)" ; Get next PID
|
||||||
|
|
||||||
|
${Unless} $0 = 0
|
||||||
|
Push $0
|
||||||
|
Call GetProcessName
|
||||||
|
Pop $1
|
||||||
|
|
||||||
|
# is this process one we are looking for?
|
||||||
|
${WordFind} '$2' ',' 'E/$1' $0
|
||||||
|
${Unless} ${Errors}
|
||||||
|
# yes, change return value
|
||||||
|
Pop $0 ; discard old result
|
||||||
|
Push 1 ; set return True
|
||||||
|
|
||||||
|
# exit the loop
|
||||||
|
${Break}
|
||||||
|
${EndUnless}
|
||||||
|
${EndUnless}
|
||||||
|
${Next}
|
||||||
|
|
||||||
|
${EndUnless}
|
||||||
|
|
||||||
|
System::Free $R0
|
||||||
|
|
||||||
|
Pop $0 ; get return value
|
||||||
|
Pop $R2 ; restore registers
|
||||||
|
Pop $R1
|
||||||
|
Pop $R0
|
||||||
|
Pop $2
|
||||||
|
Pop $1
|
||||||
|
Exch $0
|
||||||
|
FunctionEnd
|
||||||
|
|
||||||
|
Function GetProcessName
|
||||||
|
# ( Pid -- ProcessName )
|
||||||
|
Exch $2 ; get Pid, save $2
|
||||||
|
Push $0
|
||||||
|
Push $1
|
||||||
|
Push $3
|
||||||
|
Push $R0
|
||||||
|
|
||||||
|
System::Call "Kernel32::OpenProcess(i 1040, i 0, i r2)i .r3"
|
||||||
|
|
||||||
|
StrCpy $2 "<unknown>" ; set return value
|
||||||
|
|
||||||
|
${Unless} $3 = 0 ; $3 is hProcess
|
||||||
|
# get hMod array
|
||||||
|
System::Alloc 1024
|
||||||
|
Pop $R0
|
||||||
|
|
||||||
|
# params: Pid, &hMod, sizeof(hMod), &cb
|
||||||
|
System::Call "Psapi::EnumProcessModules(i r3, i R0, i 1024, *i .r1)i .r0"
|
||||||
|
|
||||||
|
${Unless} $0 = 0
|
||||||
|
# get first hMod
|
||||||
|
System::Call "*$R0(i .r0)"
|
||||||
|
|
||||||
|
# get BaseName; params: Pid, hMod, szBuffer, sizeof(szBuffer)
|
||||||
|
System::Call "Psapi::GetModuleBaseName(i r3, i r0, t .r2, i 256)i .r0"
|
||||||
|
${EndUnless}
|
||||||
|
|
||||||
|
System::Free $R0
|
||||||
|
System::Call "kernel32::CloseHandle(i r3)"
|
||||||
|
${EndUnless}
|
||||||
|
|
||||||
|
Pop $R0 ; restore registers
|
||||||
|
Pop $3
|
||||||
|
Pop $1
|
||||||
|
Pop $0
|
||||||
|
Exch $2 ; save process name
|
||||||
|
FunctionEnd
|
||||||
|
!endif
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
# uncomment on v3
|
# This now requires v3
|
||||||
# UniCode true
|
UniCode true
|
||||||
|
|
||||||
!define APPNAME "I2PBrowser-Launcher"
|
!define APPNAME "I2PBrowser-Launcher"
|
||||||
!define COMPANYNAME "I2P"
|
!define COMPANYNAME "I2P"
|
||||||
@@ -11,11 +11,16 @@
|
|||||||
!define CONSOLE_URL "http://127.0.0.1:7657/home"
|
!define CONSOLE_URL "http://127.0.0.1:7657/home"
|
||||||
|
|
||||||
!include i2pbrowser-version.nsi
|
!include i2pbrowser-version.nsi
|
||||||
|
!include i2pbrowser-jpackage.nsi
|
||||||
|
!include FindProcess.nsh
|
||||||
|
|
||||||
var FFINSTEXE
|
var FFINSTEXE
|
||||||
|
var FFNONTORINSTEXE
|
||||||
var I2PINSTEXE
|
var I2PINSTEXE
|
||||||
|
|
||||||
|
|
||||||
!define FFINSTEXE
|
!define FFINSTEXE
|
||||||
|
!define FFNONTORINSTEXE
|
||||||
!define FFINSTEXE32 "$PROGRAMFILES32\Mozilla Firefox\"
|
!define FFINSTEXE32 "$PROGRAMFILES32\Mozilla Firefox\"
|
||||||
!define FFINSTEXE64 "$PROGRAMFILES64\Mozilla Firefox\"
|
!define FFINSTEXE64 "$PROGRAMFILES64\Mozilla Firefox\"
|
||||||
|
|
||||||
@@ -25,14 +30,14 @@ var I2PINSTEXE
|
|||||||
|
|
||||||
!define RAM_NEEDED_FOR_64BIT 0x80000000
|
!define RAM_NEEDED_FOR_64BIT 0x80000000
|
||||||
|
|
||||||
InstallDir "$PROGRAMFILES\${COMPANYNAME}\${APPNAME}"
|
InstallDir "$PROGRAMFILES64\${COMPANYNAME}\${APPNAME}"
|
||||||
|
|
||||||
# rtf or txt file - remember if it is txt, it must be in the DOS text format (\r\n)
|
# rtf or txt file - remember if it is txt, it must be in the DOS text format (\r\n)
|
||||||
LicenseData "licenses\LICENSE.index"
|
LicenseData "licenses\LICENSE.index"
|
||||||
# This will be in the installer/uninstaller's title bar
|
# This will be in the installer/uninstaller's title bar
|
||||||
Name "${COMPANYNAME} - ${APPNAME}"
|
Name "${COMPANYNAME} - ${APPNAME}"
|
||||||
Icon ui2pbrowser_icon.ico
|
Icon ui2pbrowser_icon.ico
|
||||||
OutFile "I2P-Profile-Installer-${VERSIONMAJOR}.${VERSIONMINOR}${VERSIONBUILD}.exe"
|
OutFile "I2P-Profile-Installer-${VERSIONMAJOR}.${VERSIONMINOR}.${VERSIONBUILD}.exe"
|
||||||
|
|
||||||
RequestExecutionLevel admin
|
RequestExecutionLevel admin
|
||||||
|
|
||||||
@@ -125,6 +130,7 @@ PageExEnd
|
|||||||
PageEx directory
|
PageEx directory
|
||||||
dirtext "${FIREFOX_MESSAGE}"
|
dirtext "${FIREFOX_MESSAGE}"
|
||||||
dirvar $FFINSTEXE
|
dirvar $FFINSTEXE
|
||||||
|
dirvar $FFNONTORINSTEXE
|
||||||
PageCallbacks firefoxDetect
|
PageCallbacks firefoxDetect
|
||||||
PageExEnd
|
PageExEnd
|
||||||
PageEx directory
|
PageEx directory
|
||||||
@@ -143,8 +149,10 @@ Function .onInit
|
|||||||
${If} $0 == 1
|
${If} $0 == 1
|
||||||
${If} ${FileExists} "${FFINSTEXE64}/firefox.exe"
|
${If} ${FileExists} "${FFINSTEXE64}/firefox.exe"
|
||||||
StrCpy $FFINSTEXE "${FFINSTEXE64}"
|
StrCpy $FFINSTEXE "${FFINSTEXE64}"
|
||||||
${ElseIf} ${FileExists} "${FFINSTEXE32}/firefox.exe"
|
StrCpy $FFNONTORINSTEXE "${FFINSTEXE64}"
|
||||||
StrCpy $FFINSTEXE "${FFINSTEXE32}"
|
${ElseIf} ${FileExists} "${FFINSTEXE32}/firefox.exe"
|
||||||
|
StrCpy $FFINSTEXE "${FFINSTEXE32}"
|
||||||
|
StrCpy $FFNONTORINSTEXE "${FFINSTEXE32}"
|
||||||
${EndIf}
|
${EndIf}
|
||||||
${If} ${FileExists} "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/firefox.exe"
|
${If} ${FileExists} "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/firefox.exe"
|
||||||
StrCpy $FFINSTEXE "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/"
|
StrCpy $FFINSTEXE "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/"
|
||||||
@@ -155,6 +163,7 @@ Function .onInit
|
|||||||
${Else}
|
${Else}
|
||||||
${If} ${FileExists} "${FFINSTEXE32}/firefox.exe"
|
${If} ${FileExists} "${FFINSTEXE32}/firefox.exe"
|
||||||
StrCpy $FFINSTEXE "${FFINSTEXE32}"
|
StrCpy $FFINSTEXE "${FFINSTEXE32}"
|
||||||
|
StrCpy $FFNONTORINSTEXE "${FFINSTEXE32}"
|
||||||
${EndIf}
|
${EndIf}
|
||||||
${If} ${FileExists} "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/firefox.exe"
|
${If} ${FileExists} "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/firefox.exe"
|
||||||
StrCpy $FFINSTEXE "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/"
|
StrCpy $FFINSTEXE "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/"
|
||||||
@@ -163,10 +172,11 @@ Function .onInit
|
|||||||
StrCpy $FFINSTEXE "$PROFILE/Desktop/Tor Browser/Browser/"
|
StrCpy $FFINSTEXE "$PROFILE/Desktop/Tor Browser/Browser/"
|
||||||
${EndIf}
|
${EndIf}
|
||||||
${EndIf}
|
${EndIf}
|
||||||
${If} ${FileExists} "${I2PINSTEXE32}"
|
StrCpy $I2PINSTEXE "${I2PINSTEXE64}"
|
||||||
|
${If} ${FileExists} "${I2PINSTEXE32}\i2p.exe"
|
||||||
StrCpy $I2PINSTEXE "${I2PINSTEXE32}"
|
StrCpy $I2PINSTEXE "${I2PINSTEXE32}"
|
||||||
${EndIf}
|
${EndIf}
|
||||||
${If} ${FileExists} "${I2PINSTEXE64}"
|
${If} ${FileExists} "${I2PINSTEXE64}\i2p.exe"
|
||||||
StrCpy $I2PINSTEXE "${I2PINSTEXE64}"
|
StrCpy $I2PINSTEXE "${I2PINSTEXE64}"
|
||||||
${EndIf}
|
${EndIf}
|
||||||
FunctionEnd
|
FunctionEnd
|
||||||
@@ -179,6 +189,36 @@ FunctionEnd
|
|||||||
|
|
||||||
Function routerDetect
|
Function routerDetect
|
||||||
${If} ${FileExists} "$I2PINSTEXE"
|
${If} ${FileExists} "$I2PINSTEXE"
|
||||||
|
Abort directory
|
||||||
|
${Else}
|
||||||
|
createDirectory $I2PINSTEXE
|
||||||
|
SetOutPath $I2PINSTEXE
|
||||||
|
File /nonfatal /a /r "I2P\"
|
||||||
|
File /nonfatal "I2P\config\jpackaged"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\"
|
||||||
|
SetOutPath "$I2PINSTEXE\"
|
||||||
|
File /nonfatal "I2P\config\clients.config"
|
||||||
|
File /nonfatal "I2P\config\i2ptunnel.config"
|
||||||
|
File /nonfatal "I2P\config\wrapper.config"
|
||||||
|
File /nonfatal "I2P\config\hosts.txt"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\webapps\"
|
||||||
|
SetOutPath "$I2PINSTEXE\webapps\"
|
||||||
|
File /nonfatal /a /r "I2P\config\webapps\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\geoip\"
|
||||||
|
SetOutPath "$I2PINSTEXE\geoip\"
|
||||||
|
File /nonfatal /a /r "I2P\config\geoip\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\certificates\"
|
||||||
|
SetOutPath "$I2PINSTEXE\certificates\"
|
||||||
|
File /nonfatal /a /r "I2P\config\certificates\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\eepsite\"
|
||||||
|
SetOutPath "$I2PINSTEXE\eepsite\"
|
||||||
|
File /nonfatal /a /r "I2P\config\eepsite\"
|
||||||
|
|
||||||
Abort directory
|
Abort directory
|
||||||
${EndIf}
|
${EndIf}
|
||||||
FunctionEnd
|
FunctionEnd
|
||||||
@@ -186,37 +226,71 @@ FunctionEnd
|
|||||||
# start default section
|
# start default section
|
||||||
Section Install
|
Section Install
|
||||||
|
|
||||||
|
${If} ${Silent}
|
||||||
|
${Do}
|
||||||
|
${FindProcess} "I2P.exe" $0
|
||||||
|
Sleep 500
|
||||||
|
${LoopWhile} $0 <> 0
|
||||||
|
${EndIf}
|
||||||
|
|
||||||
# set the installation directory as the destination for the following actions
|
# set the installation directory as the destination for the following actions
|
||||||
createDirectory $INSTDIR
|
createDirectory $INSTDIR
|
||||||
SetOutPath $INSTDIR
|
SetOutPath $INSTDIR
|
||||||
File ui2pbrowser_icon.ico
|
File ui2pbrowser_icon.ico
|
||||||
|
|
||||||
# Install the launcher scripts: This will need to be it's own section, since
|
# Update jpackaged I2P router, if it exists
|
||||||
# now I think we just need to let the user select if the user is using a non
|
${If} ${FileExists} "$I2PINSTEXE\jpackaged"
|
||||||
# default Firefox path.
|
createDirectory $I2PINSTEXE
|
||||||
FileOpen $0 "$INSTDIR\i2pbrowser.bat" w
|
SetOutPath $I2PINSTEXE
|
||||||
FileWrite $0 "@echo off"
|
|
||||||
FileWriteByte $0 "13"
|
|
||||||
FileWriteByte $0 "10"
|
|
||||||
FileWrite $0 'start "" "$FFINSTEXE\firefox.exe" -no-remote -profile "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p" -url %1'
|
|
||||||
FileWriteByte $0 "13"
|
|
||||||
FileWriteByte $0 "10"
|
|
||||||
FileWrite $0 exit
|
|
||||||
FileWriteByte $0 "13"
|
|
||||||
FileWriteByte $0 "10"
|
|
||||||
FileClose $0
|
|
||||||
|
|
||||||
FileOpen $0 "$INSTDIR\i2pbrowser-private.bat" w
|
${If} ${Silent}
|
||||||
FileWrite $0 "@echo off"
|
ReadEnvStr $0 OLD_I2P_VERSION
|
||||||
FileWriteByte $0 "13"
|
${If} $0 < ${I2P_VERSION}
|
||||||
FileWriteByte $0 "10"
|
File /nonfatal /a /r "I2P\"
|
||||||
FileWrite $0 'start "" "$FFINSTEXE\firefox.exe" -no-remote -profile "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p" -private-window about:blank'
|
File /nonfatal "I2P\config\jpackaged"
|
||||||
FileWriteByte $0 "13"
|
|
||||||
FileWriteByte $0 "10"
|
createDirectory "$I2PINSTEXE\"
|
||||||
FileWrite $0 exit
|
SetOutPath "$I2PINSTEXE\"
|
||||||
FileWriteByte $0 "13"
|
|
||||||
FileWriteByte $0 "10"
|
createDirectory "$I2PINSTEXE\webapps\"
|
||||||
FileClose $0
|
SetOutPath "$I2PINSTEXE\webapps\"
|
||||||
|
File /nonfatal /a /r "I2P\config\webapps\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\geoip\"
|
||||||
|
SetOutPath "$I2PINSTEXE\geoip\"
|
||||||
|
File /nonfatal /a /r "I2P\config\geoip\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\certificates\"
|
||||||
|
SetOutPath "$I2PINSTEXE\certificates\"
|
||||||
|
File /nonfatal /a /r "I2P\config\certificates\"
|
||||||
|
${EndIf}
|
||||||
|
${Else}
|
||||||
|
File /nonfatal /a /r "I2P\"
|
||||||
|
File /nonfatal "I2P\config\jpackaged"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\"
|
||||||
|
SetOutPath "$I2PINSTEXE\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\webapps\"
|
||||||
|
SetOutPath "$I2PINSTEXE\webapps\"
|
||||||
|
File /nonfatal /a /r "I2P\config\webapps\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\geoip\"
|
||||||
|
SetOutPath "$I2PINSTEXE\geoip\"
|
||||||
|
File /nonfatal /a /r "I2P\config\geoip\"
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE\certificates\"
|
||||||
|
SetOutPath "$I2PINSTEXE\certificates\"
|
||||||
|
File /nonfatal /a /r "I2P\config\certificates\"
|
||||||
|
${EndIf}
|
||||||
|
${EndIf}
|
||||||
|
|
||||||
|
# Install the launcher scripts
|
||||||
|
createDirectory "$INSTDIR\licenses"
|
||||||
|
SetOutPath "$INSTDIR"
|
||||||
|
File win/i2pbrowser.bat
|
||||||
|
File win/i2pbrowser-private.bat
|
||||||
|
File win/i2pconfig.bat
|
||||||
|
|
||||||
# Install the licenses
|
# Install the licenses
|
||||||
createDirectory "$INSTDIR\licenses"
|
createDirectory "$INSTDIR\licenses"
|
||||||
@@ -224,43 +298,87 @@ Section Install
|
|||||||
File /r licenses\*.*
|
File /r licenses\*.*
|
||||||
|
|
||||||
# Install the profile
|
# Install the profile
|
||||||
createDirectory "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p"
|
createDirectory "$INSTDIR\firefox.profile.i2p"
|
||||||
SetOutPath "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p"
|
SetOutPath "$INSTDIR\firefox.profile.i2p"
|
||||||
File profile/user.js
|
File profile\user.js
|
||||||
File profile/prefs.js
|
File profile\prefs.js
|
||||||
File profile/bookmarks.html
|
File profile\bookmarks.html
|
||||||
File profile/storage-sync.sqlite
|
File profile\storage-sync.sqlite
|
||||||
|
|
||||||
# Install the extensions
|
# Install the extensions
|
||||||
createDirectory "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\extensions"
|
createDirectory "$INSTDIR\firefox.profile.i2p\extensions"
|
||||||
SetOutPath "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\extensions"
|
SetOutPath "$INSTDIR\firefox.profile.i2p\extensions"
|
||||||
File "profile/extensions/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
File "profile\extensions\{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||||
File profile/extensions/https-everywhere-eff@eff.org.xpi
|
File profile\extensions\https-everywhere-eff@eff.org.xpi
|
||||||
File profile/extensions/i2ppb@eyedeekay.github.io.xpi
|
File profile\extensions\i2prhz@eyedeekay.github.io.xpi
|
||||||
|
|
||||||
|
# Install the config profile
|
||||||
|
createDirectory "$INSTDIR\firefox.profile.config.i2p"
|
||||||
|
SetOutPath "$INSTDIR\firefox.profile.config.i2p"
|
||||||
|
File app-profile\user.js
|
||||||
|
File app-profile\prefs.js
|
||||||
|
File app-profile\bookmarks.html
|
||||||
|
File app-profile\storage-sync.sqlite
|
||||||
|
|
||||||
|
# Install the config extensions
|
||||||
|
createDirectory "$INSTDIR\firefox.profile.config.i2p\extensions"
|
||||||
|
SetOutPath "$INSTDIR\firefox.profile.config.i2p\extensions"
|
||||||
|
File profile\extensions\https-everywhere-eff@eff.org.xpi
|
||||||
|
File profile\extensions\i2prhz@eyedeekay.github.io.xpi
|
||||||
|
|
||||||
|
# Install the config userChrome
|
||||||
|
createDirectory "$INSTDIR\firefox.profile.config.i2p\chrome"
|
||||||
|
SetOutPath "$INSTDIR\firefox.profile.config.i2p\chrome"
|
||||||
|
File app-profile\chrome\userChrome.css
|
||||||
|
|
||||||
SetOutPath "$INSTDIR"
|
SetOutPath "$INSTDIR"
|
||||||
createDirectory "$SMPROGRAMS\${APPNAME}"
|
createDirectory "$SMPROGRAMS\${APPNAME}"
|
||||||
CreateShortCut "$SMPROGRAMS\${APPNAME}\${APPNAME}.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser.bat$\" ${CONSOLE_URL}" "$INSTDIR\ui2pbrowser_icon.ico"
|
CreateShortCut "$SMPROGRAMS\${APPNAME}\Browse I2P.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser.bat$\" ${CONSOLE_URL}" "$INSTDIR\ui2pbrowser_icon.ico"
|
||||||
CreateShortCut "$SMPROGRAMS\${APPNAME}\Private Browsing-${APPNAME}.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser-private.bat$\"" "$INSTDIR\ui2pbrowser_icon.ico"
|
CreateShortCut "$SMPROGRAMS\${APPNAME}\Browse I2P - Temporary Identity.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser-private.bat$\"" "$INSTDIR\ui2pbrowser_icon.ico"
|
||||||
CreateShortCut "$DESKTOP\${APPNAME}.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser.bat$\" ${CONSOLE_URL}" "$INSTDIR\ui2pbrowser_icon.ico"
|
; CreateShortCut "$SMPROGRAMS\${APPNAME}\I2P Applications.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pconfig.bat$\"" "$INSTDIR\ui2pbrowser_icon.ico"
|
||||||
CreateShortCut "$DESKTOP\Private Browsing-${APPNAME}.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser-private.bat$\"" "$INSTDIR\ui2pbrowser_icon.ico"
|
|
||||||
|
|
||||||
|
CreateShortCut "$DESKTOP\Browse I2P.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser.bat$\" ${CONSOLE_URL}" "$INSTDIR\ui2pbrowser_icon.ico"
|
||||||
|
CreateShortCut "$DESKTOP\Browse I2P - Temporary Identity.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pbrowser-private.bat$\"" "$INSTDIR\ui2pbrowser_icon.ico"
|
||||||
|
; CreateShortCut "$DESKTOP\I2P Applications.lnk" "C:\Windows\system32\cmd.exe" "/c $\"$INSTDIR\i2pconfig.bat$\"" "$INSTDIR\ui2pbrowser_icon.ico"
|
||||||
|
|
||||||
SetShellVarContext current
|
;# Point the browser config setting in the base router.config
|
||||||
!define I2PAPPDATA "$APPDATA\I2P\"
|
FileOpen $0 "$I2PINSTEXE\router.config" a
|
||||||
|
|
||||||
SetOutPath "${I2PAPPDATA}"
|
|
||||||
|
|
||||||
;# Point the browser config setting
|
|
||||||
FileOpen $0 "${I2PAPPDATA}\router.config" a
|
|
||||||
FileSeek $0 0 END
|
FileSeek $0 0 END
|
||||||
FileWriteByte $0 "13"
|
FileWriteByte $0 "13"
|
||||||
FileWriteByte $0 "10"
|
FileWriteByte $0 "10"
|
||||||
FileWrite $0 "routerconsole.browser=$\"$INSTDIR\i2pbrowser.bat$\""
|
FileWrite $0 "routerconsole.browser=$\"$INSTDIR\i2pconfig.bat$\""
|
||||||
FileWriteByte $0 "13"
|
FileWriteByte $0 "13"
|
||||||
FileWriteByte $0 "10"
|
FileWriteByte $0 "10"
|
||||||
FileClose $0
|
FileClose $0
|
||||||
|
|
||||||
|
SetShellVarContext current
|
||||||
|
Var /Global I2PAPPDATA
|
||||||
|
|
||||||
|
IfFileExists "$I2PINSTEXE\clients.config" 0 +2
|
||||||
|
StrCpy $I2PAPPDATA "$I2PINSTEXE"
|
||||||
|
IfFileExists "$APPDATA\I2P\clients.config.d" 0 +2
|
||||||
|
StrCpy $I2PAPPDATA "$APPDATA\I2P\"
|
||||||
|
IfFileExists "$LOCALAPPDATA\I2P\clients.config.d" 0 +2
|
||||||
|
StrCpy $I2PAPPDATA "$LOCALAPPDATA\I2P\"
|
||||||
|
IfFileExists "$LOCALAPPDATA\I2P\clients.config" 0 +2
|
||||||
|
StrCpy $I2PAPPDATA "$LOCALAPPDATA\I2P\"
|
||||||
|
|
||||||
|
createDirectory "$I2PAPPDATA"
|
||||||
|
SetOutPath "$I2PAPPDATA"
|
||||||
|
|
||||||
|
;# Point the browser config setting in the working config
|
||||||
|
FileOpen $0 "$I2PAPPDATA\router.config" a
|
||||||
|
FileSeek $0 0 END
|
||||||
|
FileWriteByte $0 "13"
|
||||||
|
FileWriteByte $0 "10"
|
||||||
|
FileWrite $0 "routerconsole.browser=$\"$INSTDIR\i2pconfig.bat$\""
|
||||||
|
FileWriteByte $0 "13"
|
||||||
|
FileWriteByte $0 "10"
|
||||||
|
FileClose $0
|
||||||
|
|
||||||
|
createDirectory "$I2PINSTEXE"
|
||||||
|
SetOutPath "$I2PINSTEXE"
|
||||||
|
|
||||||
SetOutPath "$INSTDIR"
|
SetOutPath "$INSTDIR"
|
||||||
# create the uninstaller
|
# create the uninstaller
|
||||||
WriteUninstaller "$INSTDIR\uninstall-i2pbrowser.exe"
|
WriteUninstaller "$INSTDIR\uninstall-i2pbrowser.exe"
|
||||||
@@ -278,19 +396,30 @@ Section "uninstall"
|
|||||||
|
|
||||||
# Uninstall the launcher scripts
|
# Uninstall the launcher scripts
|
||||||
Delete $INSTDIR\i2pbrowser.bat
|
Delete $INSTDIR\i2pbrowser.bat
|
||||||
|
Delete $INSTDIR\i2pconfig.bat
|
||||||
Delete $INSTDIR\i2pbrowser-private.bat
|
Delete $INSTDIR\i2pbrowser-private.bat
|
||||||
Delete $INSTDIR\ui2pbrowser_icon.ico
|
Delete $INSTDIR\ui2pbrowser_icon.ico
|
||||||
|
|
||||||
# Uninstall the profile
|
# Uninstall the profile
|
||||||
Delete $LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\prefs.js
|
Delete $INSTDIR\firefox.profile.i2p\prefs.js
|
||||||
Delete $LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\user.js
|
Delete $INSTDIR\firefox.profile.i2p\user.js
|
||||||
Delete $LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\bookmarks.html
|
Delete $INSTDIR\firefox.profile.i2p\bookmarks.html
|
||||||
Delete $LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\storage-sync.sqlite
|
Delete $INSTDIR\firefox.profile.i2p\storage-sync.sqlite
|
||||||
|
|
||||||
|
Delete $INSTDIR\firefox.profile.config.i2p\prefs.js
|
||||||
|
Delete $INSTDIR\firefox.profile.config.i2p\user.js
|
||||||
|
Delete $INSTDIR\firefox.profile.config.i2p\bookmarks.html
|
||||||
|
Delete $INSTDIR\firefox.profile.config.i2p\storage-sync.sqlite
|
||||||
|
|
||||||
# Uninstall the extensions
|
# Uninstall the extensions
|
||||||
Delete "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\extensions\{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
Delete "$INSTDIR\firefox.profile.i2p\extensions\{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||||
Delete "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\extensions\https-everywhere-eff@eff.org.xpi"
|
Delete "$INSTDIR\firefox.profile.i2p\extensions\https-everywhere-eff@eff.org.xpi"
|
||||||
Delete "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\extensions\i2ppb@eyedeekay.github.io.xpi"
|
Delete "$INSTDIR\firefox.profile.i2p\extensions\i2prhz@eyedeekay.github.io.xpi"
|
||||||
|
|
||||||
|
Delete "$INSTDIR\firefox.profile.config.i2p\extensions\https-everywhere-eff@eff.org.xpi"
|
||||||
|
Delete "$INSTDIR\firefox.profile.config.i2p\extensions\i2prhz@eyedeekay.github.io.xpi"
|
||||||
|
|
||||||
|
Delete "$INSTDIR\firefox.profile.config.i2p\config\userChrome.css"
|
||||||
|
|
||||||
# Remove shortcuts and folders
|
# Remove shortcuts and folders
|
||||||
Delete "$SMPROGRAMS\${APPNAME}\${APPNAME}.lnk"
|
Delete "$SMPROGRAMS\${APPNAME}\${APPNAME}.lnk"
|
||||||
@@ -299,11 +428,14 @@ Section "uninstall"
|
|||||||
Delete "$DESKTOP\${APPNAME}.lnk"
|
Delete "$DESKTOP\${APPNAME}.lnk"
|
||||||
Delete "$DESKTOP\Private Browsing-${APPNAME}.lnk"
|
Delete "$DESKTOP\Private Browsing-${APPNAME}.lnk"
|
||||||
rmDir "$SMPROGRAMS\${APPNAME}"
|
rmDir "$SMPROGRAMS\${APPNAME}"
|
||||||
rmDir "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p\extensions"
|
rmDir "$INSTDIR\firefox.profile.i2p\extensions"
|
||||||
rmDir "$LOCALAPPDATA\${APPNAME}\firefox.profile.i2p"
|
rmDir "$INSTDIR\firefox.profile.i2p"
|
||||||
rmDir "$LOCALAPPDATA\${APPNAME}"
|
rmDir "$LOCALAPPDATA\${APPNAME}"
|
||||||
rmDir "$INSTDIR"
|
rmDir "$INSTDIR"
|
||||||
|
|
||||||
|
${If} ${FileExists} "$I2PINSTEXE\jpackaged"
|
||||||
|
rmDir "$I2PINSTEXE"
|
||||||
|
${EndIf}
|
||||||
# delete the uninstaller
|
# delete the uninstaller
|
||||||
Delete "$INSTDIR\uninstall-i2pbrowser.exe"
|
Delete "$INSTDIR\uninstall-i2pbrowser.exe"
|
||||||
|
|
||||||
@@ -317,5 +449,12 @@ SectionEnd
|
|||||||
!insertmacro MUI_PAGE_FINISH
|
!insertmacro MUI_PAGE_FINISH
|
||||||
|
|
||||||
Function LaunchLink
|
Function LaunchLink
|
||||||
ExecShell "" "$SMPROGRAMS\${APPNAME}\${APPNAME}.lnk"
|
${If} ${Silent}
|
||||||
|
ReadEnvStr $0 RESTART_I2P
|
||||||
|
${If} $0 != ""
|
||||||
|
Exec "$INSTDIR\i2pbrowser.bat"
|
||||||
|
${EndIf}
|
||||||
|
${Else}
|
||||||
|
Exec "$INSTDIR\i2pbrowser.bat"
|
||||||
|
${EndIf}
|
||||||
FunctionEnd
|
FunctionEnd
|
||||||
|
|||||||
1
src/nsis/i2pbrowser-jpackage.nsi
Normal file
1
src/nsis/i2pbrowser-jpackage.nsi
Normal file
@@ -0,0 +1 @@
|
|||||||
|
!define I2P_VERSION 0.9.50
|
||||||
@@ -1,3 +1,3 @@
|
|||||||
!define VERSIONMAJOR 0
|
!define VERSIONMAJOR 0
|
||||||
!define VERSIONMINOR 03
|
!define VERSIONMINOR 04
|
||||||
!define VERSIONBUILD
|
!define VERSIONBUILD 0
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ user_pref("privacy.firstparty.isolate", true);
|
|||||||
// Use i2p http proxy for all connections and set homepage to safe local form.
|
// Use i2p http proxy for all connections and set homepage to safe local form.
|
||||||
|
|
||||||
// DON'T allow access to the admin panel from the profile we browse i2p with.
|
// DON'T allow access to the admin panel from the profile we browse i2p with.
|
||||||
user_pref("network.proxy.no_proxies_on", 0);
|
user_pref("network.proxy.no_proxies_on", "127.0.0.1:7657,localhost:7657,127.0.0.1:7662,localhost:7662,127.0.0.1:7669,localhost:7669");
|
||||||
user_pref("network.proxy.type", 1);
|
user_pref("network.proxy.type", 1);
|
||||||
user_pref("network.proxy.http", "127.0.0.1");
|
user_pref("network.proxy.http", "127.0.0.1");
|
||||||
user_pref("network.proxy.http_port", 4444);
|
user_pref("network.proxy.http_port", 4444);
|
||||||
@@ -40,3 +40,21 @@ user_pref("network.proxy.socks_port", 4444);
|
|||||||
user_pref("network.proxy.share_proxy_settings", true);
|
user_pref("network.proxy.share_proxy_settings", true);
|
||||||
user_pref("browser.startup.homepage", "about:blank");
|
user_pref("browser.startup.homepage", "about:blank");
|
||||||
user_pref("dom.security.https_only_mode", false);
|
user_pref("dom.security.https_only_mode", false);
|
||||||
|
user_pref("keyword.enabled", false);
|
||||||
|
user_pref("extensions.allowPrivateBrowsingByDefault", true);
|
||||||
|
user_pref("extensions.PrivateBrowsing.notification", false);
|
||||||
|
user_pref("extensions.pocket.enabled", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSponsoredTopSites", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("services.sync.prefs.sync.browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.section.highlights", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.section.topstories", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.default.sites", "http://planet.i2p/,http://legwork.i2p/,http://i2pwiki.i2p/,http://i2pforums.i2p/,http://zzz.i2p/");
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.topsites", true);
|
||||||
|
user_pref("ui.use_standins_for_native_colors", true);
|
||||||
|
user_pref("webgl.disable-extensions", true);
|
||||||
|
user_pref("webgl.min_capability_mode", true);
|
||||||
|
user_pref("webgl.disable-fail-if-major-performance-caveat", true);
|
||||||
|
user_pref("webgl.enable-webgl2", false);
|
||||||
|
user_pref("media.navigator.enabled", false);
|
||||||
|
user_pref("dom.w3c_touch_events.enabled", false);
|
||||||
|
|||||||
@@ -95,7 +95,7 @@ user_pref("privacy.firstparty.isolate", true);
|
|||||||
// Use i2p http proxy for all connections and set homepage to safe local form.
|
// Use i2p http proxy for all connections and set homepage to safe local form.
|
||||||
|
|
||||||
// DON'T allow access to the admin panel from the profile we browse i2p with.
|
// DON'T allow access to the admin panel from the profile we browse i2p with.
|
||||||
user_pref("network.proxy.no_proxies_on", 0);
|
user_pref("network.proxy.no_proxies_on", "127.0.0.1:7657,localhost:7657,127.0.0.1:7662,localhost:7662,127.0.0.1:7669,localhost:7669");
|
||||||
user_pref("network.proxy.type", 1);
|
user_pref("network.proxy.type", 1);
|
||||||
user_pref("network.proxy.http", "127.0.0.1");
|
user_pref("network.proxy.http", "127.0.0.1");
|
||||||
user_pref("network.proxy.http_port", 4444);
|
user_pref("network.proxy.http_port", 4444);
|
||||||
@@ -170,7 +170,7 @@ user_pref("dom.serviceWorkers.enabled", false);
|
|||||||
user_pref("dom.serviceWorkers.interception.enabled", false);
|
user_pref("dom.serviceWorkers.interception.enabled", false);
|
||||||
user_pref("dom.storage.enabled", false);
|
user_pref("dom.storage.enabled", false);
|
||||||
user_pref("dom.webaudio.enabled", false);
|
user_pref("dom.webaudio.enabled", false);
|
||||||
user_pref("extensions.autoDisableScopes", 14);
|
user_pref("extensions.autoDisableScopes", 0);
|
||||||
user_pref("extensions.getAddons.cache.enabled", false);
|
user_pref("extensions.getAddons.cache.enabled", false);
|
||||||
user_pref("extensions.getAddons.showPane", false);
|
user_pref("extensions.getAddons.showPane", false);
|
||||||
user_pref("extensions.pocket.enabled", false);
|
user_pref("extensions.pocket.enabled", false);
|
||||||
@@ -205,6 +205,20 @@ user_pref("toolkit.telemetry.unified", false);
|
|||||||
user_pref("webgl.disabled", true);
|
user_pref("webgl.disabled", true);
|
||||||
user_pref("browser.chrome.errorReporter.infoURL", "");
|
user_pref("browser.chrome.errorReporter.infoURL", "");
|
||||||
user_pref("breakpad.reportURL", "");
|
user_pref("breakpad.reportURL", "");
|
||||||
user_pref("browser.newtabpage.activity-stream.default.sites", "");
|
//user_pref("browser.newtabpage.activity-stream.default.sites", "");
|
||||||
//user_pref("browser.newtabpage.activity-stream.default.sites", "http://planet.i2p/,http://legwork.i2p/,http://i2pwiki.i2p/,http://i2pforums.i2p/,http://zzz.i2p/");
|
user_pref("browser.newtabpage.activity-stream.showSponsoredTopSites", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("services.sync.prefs.sync.browser.newtabpage.activity-stream.showSponsored", false);
|
||||||
|
user_pref("browser.newtabpage.enabled", true);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.default.sites", "http://planet.i2p/,http://legwork.i2p/,http://i2pwiki.i2p/,http://i2pforums.i2p/,http://zzz.i2p/");
|
||||||
user_pref("dom.security.https_only_mode", false);
|
user_pref("dom.security.https_only_mode", false);
|
||||||
|
user_pref("keyword.enabled", false);
|
||||||
|
user_pref("extensions.allowPrivateBrowsingByDefault", true);
|
||||||
|
user_pref("extensions.PrivateBrowsing.notification", false);
|
||||||
|
user_pref("browser.newtabpage.activity-stream.feeds.topsites", true);
|
||||||
|
user_pref("ui.use_standins_for_native_colors", true);
|
||||||
|
user_pref("webgl.disable-extensions", true);
|
||||||
|
user_pref("webgl.min_capability_mode", true);
|
||||||
|
user_pref("webgl.disable-fail-if-major-performance-caveat", true);
|
||||||
|
user_pref("webgl.enable-webgl2", false);
|
||||||
|
user_pref("dom.w3c_touch_events.enabled", false);
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
0.3
|
0.04.0
|
||||||
|
|||||||
9
src/unix/desktop/i2pbrowser.desktop
Normal file
9
src/unix/desktop/i2pbrowser.desktop
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
[Desktop Entry]
|
||||||
|
Encoding=UTF-8
|
||||||
|
Version=1.0
|
||||||
|
Type=Application
|
||||||
|
Terminal=false
|
||||||
|
Exec=/usr/local/bin/i2pbrowser
|
||||||
|
Name=I2P Browser
|
||||||
|
Categories=Network;WebBrowser;
|
||||||
|
Icon=/var/lib/i2pbrowser/icons/ui2pbrowser_icon.ico
|
||||||
9
src/unix/desktop/i2pconfig.desktop
Normal file
9
src/unix/desktop/i2pconfig.desktop
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
[Desktop Entry]
|
||||||
|
Encoding=UTF-8
|
||||||
|
Version=1.0
|
||||||
|
Type=Application
|
||||||
|
Terminal=false
|
||||||
|
Exec=/usr/local/bin/i2pconfig
|
||||||
|
Name=I2P Configuration
|
||||||
|
Categories=Network;WebBrowser;
|
||||||
|
Icon=/var/lib/i2pbrowser/icons/ui2pbrowser_icon.ico
|
||||||
21
src/unix/i2p-config-service-setup.sh
Executable file
21
src/unix/i2p-config-service-setup.sh
Executable file
@@ -0,0 +1,21 @@
|
|||||||
|
#! /usr/bin/env sh
|
||||||
|
|
||||||
|
# Works for Debian service installs. Sets up minified, custom profile for configuring I2P console.
|
||||||
|
|
||||||
|
if grep '^i2psvc:' /etc/passwd; then
|
||||||
|
I2P_HOME=$(grep '^i2psvc:' /etc/passwd | sed 's|i2psvc:x:||g' | sed 's|:/usr/sbin/nologin||g' | tr -d ':1234567890' | sed 's|ip|i2p|g')
|
||||||
|
ROUTER_CONFIG=$(sudo -u i2psvc ls $I2P_HOME/i2p-config/router.config)
|
||||||
|
fi
|
||||||
|
|
||||||
|
installer(){
|
||||||
|
|
||||||
|
if [ $(sudo -u i2psvc ls $I2P_HOME/i2p-config/router.config) ]; then
|
||||||
|
echo $I2P_HOME $ROUTER_CONFIG $0
|
||||||
|
if ! sudo -u i2psvc grep -R 'routerconsole.browser' "$I2P_HOME/i2p-config/router.config" ; then
|
||||||
|
echo "routerconsole.browser=/usr/local/bin/i2pconfig" | sudo tee -a "$I2P_HOME/i2p-config/router.config"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
installer
|
||||||
44
src/unix/i2pbrowser.sh
Executable file
44
src/unix/i2pbrowser.sh
Executable file
@@ -0,0 +1,44 @@
|
|||||||
|
#! /usr/bin/env sh
|
||||||
|
|
||||||
|
if [ -f "/etc/i2pbrowser/i2pbrowserrc" ]; then
|
||||||
|
. /etc/i2pbrowser/i2pbrowserrc
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -z $I2PROUTER ]; then
|
||||||
|
"$I2PROUTER" start
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z $BROWSING_PROFILE ]; then
|
||||||
|
BROWSING_PROFILE="."
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -d "$BROWSING_PROFILE" ]; then
|
||||||
|
mkdir -p "$BROWSING_PROFILE"
|
||||||
|
cp -vr /var/lib/i2pbrowser/profile/* "$BROWSING_PROFILE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -f "$BROWSING_PROFILE/user.js" ]; then
|
||||||
|
echo "user.js not present in $BROWSING_PROFILE, this is not a Firefox profile"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z $FIREFOX ]; then
|
||||||
|
if [ -f "firefox/firefox" ]; then
|
||||||
|
FIREFOX="./firefox/firefox"
|
||||||
|
fi
|
||||||
|
FIREFOX=$(which firefox-esr)
|
||||||
|
if [ -z $FIREFOX ]; then
|
||||||
|
FIREFOX=$(which firefox)
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z $FIREFOX ]; then
|
||||||
|
echo "Firefox does not appear to be in your \$PATH."
|
||||||
|
echo "Please install Firefox via a package manager, or"
|
||||||
|
echo "or set the FIREFOX variable in your shell to the"
|
||||||
|
echo "location of a Firefox executable."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo $FIREFOX --profile "$BROWSING_PROFILE" $@
|
||||||
|
$FIREFOX --profile "$BROWSING_PROFILE" $@
|
||||||
17
src/unix/i2pbrowserdebianrc
Normal file
17
src/unix/i2pbrowserdebianrc
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
|
||||||
|
I2PROUTER=$(which i2prouter)
|
||||||
|
|
||||||
|
if [ -z $I2PROUTER ]; then
|
||||||
|
I2PROUTER=/usr/sbin/i2prouter
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -f $I2PROUTER ]; then
|
||||||
|
I2PROUTER="$HOME/i2p/i2prouter"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -f $I2PROUTER ]; then
|
||||||
|
I2PROUTER=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
wget -q -O - "http://localhost:7657" >/dev/null && I2PROUTER=""
|
||||||
|
echo "$I2PROUTER"
|
||||||
8
src/unix/i2pbrowserrc
Normal file
8
src/unix/i2pbrowserrc
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
|
||||||
|
if [ -f /etc/i2pbrowser/i2pbrowserdebianrc ]; then
|
||||||
|
. /etc/i2pbrowser/i2pbrowserdebianrc
|
||||||
|
fi
|
||||||
|
|
||||||
|
CONFIGURING_PROFILE=$HOME/i2p/firefox/webapps
|
||||||
|
BROWSING_PROFILE=$HOME/i2p/firefox/browsing
|
||||||
|
ROUTER_CONSOLE="127.0.0.1:7657"
|
||||||
60
src/unix/i2pconfig.sh
Executable file
60
src/unix/i2pconfig.sh
Executable file
@@ -0,0 +1,60 @@
|
|||||||
|
#! /usr/bin/env sh
|
||||||
|
|
||||||
|
if [ -f "/etc/i2pbrowser/i2pbrowserrc" ]; then
|
||||||
|
. /etc/i2pbrowser/i2pbrowserrc
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -z $I2PROUTER ]; then
|
||||||
|
"$I2PROUTER" start
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f "$HOME/.i2p/router.config" ]; then
|
||||||
|
if [ "$0" = "/usr/local/bin/i2pconfig" ]; then
|
||||||
|
if ! grep -R 'routerconsole.browser' "$HOME/.i2p/router.config" ; then
|
||||||
|
echo "routerconsole.browser=$0" | tee -a "$HOME/.i2p/router.config"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z $CONFIGURING_PROFILE ]; then
|
||||||
|
CONFIGURING_PROFILE="."
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z $ROUTER_CONSOLE ]; then
|
||||||
|
ROUTER_CONSOLE="$1"
|
||||||
|
if [ -z $1 ]; then
|
||||||
|
ROUTER_CONSOLE="http://127.0.0.1:7657"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -d "$CONFIGURING_PROFILE" ]; then
|
||||||
|
mkdir -p "$CONFIGURING_PROFILE"
|
||||||
|
cp -vr /var/lib/i2pbrowser/app-profile/* "$CONFIGURING_PROFILE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -f "$CONFIGURING_PROFILE/user.js" ]; then
|
||||||
|
echo "user.js not present in $CONFIGURING_PROFILE, this is not a Firefox profile"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z $FIREFOX ]; then
|
||||||
|
if [ -f "firefox/firefox" ]; then
|
||||||
|
FIREFOX="./firefox/firefox"
|
||||||
|
fi
|
||||||
|
FIREFOX=$(which firefox-esr)
|
||||||
|
if [ -z $FIREFOX ]; then
|
||||||
|
FIREFOX=$(which firefox)
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z $FIREFOX ]; then
|
||||||
|
echo "Firefox does not appear to be in your \$PATH."
|
||||||
|
echo "Please install Firefox via a package manager, or"
|
||||||
|
echo "or set the FIREFOX variable in your shell to the"
|
||||||
|
echo "location of a Firefox executable."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo $FIREFOX --profile "$CONFIGURING_PROFILE" "$ROUTER_CONSOLE" $@
|
||||||
|
|
||||||
|
$FIREFOX --profile "$CONFIGURING_PROFILE" "$ROUTER_CONSOLE" $@
|
||||||
38
src/win/i2pbrowser-private.bat
Normal file
38
src/win/i2pbrowser-private.bat
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
@echo on
|
||||||
|
|
||||||
|
if not exist "%ProgramFiles%\I2P\" (
|
||||||
|
set "ProgramFiles=C:\Program Files"
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%ProgramFiles%\I2P\jpackaged" (
|
||||||
|
start "i2p" /D "%LOCALAPPDATA%\I2P" "%ProgramFiles%\I2P\i2p.exe"
|
||||||
|
) else (
|
||||||
|
start "i2p" "%ProgramFiles%\I2P\i2p.exe"
|
||||||
|
)
|
||||||
|
|
||||||
|
timeout /t 3
|
||||||
|
|
||||||
|
if exist "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\" (
|
||||||
|
echo "profile is configured, updating extensions"
|
||||||
|
xcopy /s /i /y "%ProgramFiles%\I2P\I2PBrowser-Launcher\firefox.profile.i2p\extensions" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\extensions"
|
||||||
|
) else (
|
||||||
|
echo "configuring profile"
|
||||||
|
xcopy /s /i /y "%ProgramFiles%\I2P\I2PBrowser-Launcher\firefox.profile.i2p" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p"
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%USERPROFILE%/Desktop/Tor Browser/Browser/firefox.exe" (
|
||||||
|
start "i2pbrowser" "%USERPROFILE%/Desktop/Tor Browser/Browser/firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p" -private-window about:blank
|
||||||
|
exit
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%USERPROFILE%/OneDrive/Desktop/Tor Browser/Browser/firefox.exe" (
|
||||||
|
start "i2pbrowser" "%USERPROFILE%/OneDrive/Desktop/Tor Browser/Browser/firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p" -private-window about:blank
|
||||||
|
exit
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%ProgramFiles%\Mozilla Firefox\firefox.exe" (
|
||||||
|
start "i2pbrowser" "%ProgramFiles%\Mozilla Firefox\firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p" -private-window about:blank
|
||||||
|
exit
|
||||||
|
)
|
||||||
|
|
||||||
|
exit
|
||||||
38
src/win/i2pbrowser.bat
Normal file
38
src/win/i2pbrowser.bat
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
@echo on
|
||||||
|
|
||||||
|
if not exist "%ProgramFiles%\I2P\" (
|
||||||
|
set "ProgramFiles=C:\Program Files"
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%ProgramFiles%\I2P\jpackaged" (
|
||||||
|
start "i2p" /D "%LOCALAPPDATA%\I2P" "%ProgramFiles%\I2P\i2p.exe"
|
||||||
|
) else (
|
||||||
|
start "i2p" "%ProgramFiles%\I2P\i2p.exe"
|
||||||
|
)
|
||||||
|
|
||||||
|
timeout /t 3
|
||||||
|
|
||||||
|
if exist "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\" (
|
||||||
|
echo "profile is configured, updating extensions"
|
||||||
|
xcopy /s /i /y "%ProgramFiles%\I2P\I2PBrowser-Launcher\firefox.profile.i2p\extensions" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\extensions"
|
||||||
|
) else (
|
||||||
|
echo "configuring profile"
|
||||||
|
xcopy /s /i /y "%ProgramFiles%\I2P\I2PBrowser-Launcher\firefox.profile.i2p" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p"
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%USERPROFILE%/Desktop/Tor Browser/Browser/firefox.exe" (
|
||||||
|
start "i2pbrowser" "%USERPROFILE%/Desktop/Tor Browser/Browser/firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p" -url %1
|
||||||
|
exit
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%USERPROFILE%/OneDrive/Desktop/Tor Browser/Browser/firefox.exe" (
|
||||||
|
start "i2pbrowser" "%USERPROFILE%/OneDrive/Desktop/Tor Browser/Browser/firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p" -url %1
|
||||||
|
exit
|
||||||
|
)
|
||||||
|
|
||||||
|
if exist "%ProgramFiles%\Mozilla Firefox\firefox.exe" (
|
||||||
|
start "i2pbrowser" "%ProgramFiles%\Mozilla Firefox\firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p" -url %1
|
||||||
|
exit
|
||||||
|
)
|
||||||
|
|
||||||
|
exit
|
||||||
13
src/win/i2pconfig.bat
Normal file
13
src/win/i2pconfig.bat
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
@echo off
|
||||||
|
|
||||||
|
if exist "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p\" (
|
||||||
|
echo "profile is configured"
|
||||||
|
xcopy /s /i /y "$INSTDIR\firefox.profile.i2p\extensions" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\extensions"
|
||||||
|
) else (
|
||||||
|
echo "configuring profile"
|
||||||
|
xcopy /s /i /y "$INSTDIR\firefox.profile.config.i2p" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p"
|
||||||
|
)
|
||||||
|
|
||||||
|
start "i2pconfig" "c:\Program Files\Mozilla Firefox\firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p" -url %1
|
||||||
|
|
||||||
|
exit
|
||||||
Reference in New Issue
Block a user