Compare commits
67 Commits
tmp
...
settable-p
Author | SHA1 | Date | |
---|---|---|---|
aa4b1ab942 | |||
e051d4095c | |||
73f94a120e | |||
74d5ccc47f | |||
4ce272765f | |||
714ef026f3 | |||
8135506213 | |||
ffb9efaab8 | |||
706a7a6fe2 | |||
af44dd357a | |||
c64f0fe632 | |||
cf3385cfd0 | |||
ef0b5c5cad | |||
9282d22e7b | |||
400b9d3edc | |||
4aa673a959 | |||
1f543c8db5 | |||
87f9cc063b | |||
6651a16fb2 | |||
9a34008c48 | |||
1f980fb016 | |||
cf394be352 | |||
51dca79a76 | |||
bb7dcaa907 | |||
9da43b3961 | |||
a28bb6ac3c | |||
44b2ae44ee | |||
e2ad0d190a | |||
f5a424f083 | |||
fe99c7bb05 | |||
bc36564f5d | |||
d8e7551edb | |||
99ef12af4b | |||
b24caf119c | |||
e50fae0dff | |||
2776609179 | |||
91728cd98c | |||
7172b051aa | |||
3391c23abd | |||
723b4d0e27 | |||
09d07c8c88 | |||
2afeee3d56 | |||
1d0cf4aba7 | |||
cedacc64ce | |||
cef159a137 | |||
f910ec2dde | |||
36b0618b8d | |||
8200d65eb5 | |||
565ac41168 | |||
bee6a1b2a8 | |||
c7be165fb4 | |||
1f0cb37588 | |||
1c4761f3b2 | |||
77c7aede79 | |||
f58944b21a | |||
56a83972e4 | |||
34197f013d | |||
ec68e623b3 | |||
5f8dcd5f27 | |||
a152a14655 | |||
8121d08a7c | |||
0da515eedf | |||
dc219e6287 | |||
e7cee0bcf1 | |||
ab8424c767 | |||
3f89a73856 | |||
7a79341e69 |
2
.gitignore
vendored
2
.gitignore
vendored
@ -7,3 +7,5 @@ i2pversion_override
|
||||
*.crt
|
||||
*.pem
|
||||
*.p12
|
||||
.stfolder
|
||||
*.url
|
||||
|
304
Makefile
304
Makefile
@ -9,23 +9,23 @@ include .version
|
||||
|
||||
PROFILE_VERSION=$(MAJOR).$(MINOR).$(BUILD)
|
||||
|
||||
all: .version install.exe
|
||||
all: .version prep 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
|
||||
make version.txt 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
|
||||
i2pbrowser-jpackage.nsi:
|
||||
echo "!define I2P_VERSION $(I2P_VERSION)" > src/nsis/i2pbrowser-jpackage.nsi
|
||||
|
||||
jpackage: .version I2P all
|
||||
jpackage: .version I2P build/I2P/config all
|
||||
|
||||
help: .version
|
||||
@echo "I2P-Profile-Installer-$(PROFILE_VERSION)"
|
||||
@ -39,12 +39,12 @@ prep: profile.tgz app-profile.tgz profile build/licenses build/I2P build/I2P/con
|
||||
cp src/nsis/*.nsh build
|
||||
cp src/icons/*.ico build
|
||||
|
||||
install.exe: prep
|
||||
install.exe: build/licenses
|
||||
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"
|
||||
export RES_DIR="../i2p.i2p.jpackage-build/installer/resources"
|
||||
export PKG_DIR="../i2p.i2p.jpackage-build/pkg-temp"
|
||||
export I2P_JBIGI="../i2p.i2p.jpackage-build/installer/lib/jbigi"
|
||||
|
||||
distclean: clean clean-extensions
|
||||
rm -rf I2P
|
||||
@ -53,22 +53,20 @@ distclean: clean clean-extensions
|
||||
I2P:
|
||||
./build.sh
|
||||
|
||||
build/I2P: build
|
||||
build/I2P: 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
|
||||
src/I2P/config: build/I2P
|
||||
mkdir -p 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
|
||||
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
|
||||
@ -77,10 +75,10 @@ src/I2P/config:
|
||||
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
|
||||
make src/I2P/config; true
|
||||
cp -rv src/I2P/config build/I2P/config ; true
|
||||
cp -rv src/I2P/config build/I2P/.i2p ; true
|
||||
build/I2P/config: src/I2P/config build/I2P
|
||||
cp -rv src/I2P/config build/I2P/config
|
||||
# cp -rv build/I2P/* I2P/
|
||||
# cp -rv src/I2P/config build/I2P/.i2p
|
||||
|
||||
#
|
||||
# Warning: a displayed license file of more than 28752 bytes
|
||||
@ -94,284 +92,44 @@ build/licenses: build
|
||||
unix2dos build/licenses/LICENSE.index
|
||||
|
||||
clean:
|
||||
rm -rf build app-profile-*.tgz profile-*.tgz I2P-Profile-Installer-*.exe *.deb src/I2P/config *.su3 .version
|
||||
rm -rf build app-profile-*.tgz profile-*.tgz I2P-Profile-Installer-*.exe *.deb src/I2P/config *.su3 .version *.url
|
||||
git clean -fdx src build
|
||||
|
||||
build:
|
||||
@echo "creating build directory"
|
||||
mkdir -p build
|
||||
|
||||
profile: build/profile/user.js build/profile/prefs.js build/profile/bookmarks.html build/profile/storage-sync.sqlite copy-xpi
|
||||
include makefiles/profile.mk
|
||||
|
||||
profile.tgz: .version profile
|
||||
# $(eval PROFILE_VERSION := $(shell cat src/profile/version.txt))
|
||||
@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 ../
|
||||
include makefiles/app-profile.mk
|
||||
|
||||
build/profile/user.js: build/profile src/profile/user.js
|
||||
cp src/profile/user.js build/profile/user.js
|
||||
-include makefiles/new-extensions.mk
|
||||
|
||||
build/profile/prefs.js: build/profile src/profile/prefs.js
|
||||
cp src/profile/prefs.js build/profile/prefs.js
|
||||
include makefiles/extensions.mk
|
||||
|
||||
build/profile/bookmarks.html: build/profile src/profile/bookmarks.html
|
||||
cp src/profile/bookmarks.html build/profile/bookmarks.html
|
||||
include makefiles/build.mk
|
||||
|
||||
build/profile/storage-sync.sqlite: build/profile src/profile/storage-sync.sqlite
|
||||
cp src/profile/storage-sync.sqlite build/profile/storage-sync.sqlite
|
||||
include makefiles/install.mk
|
||||
|
||||
copy-xpi: build/NoScript.xpi build/HTTPSEverywhere.xpi build/i2ppb@eyedeekay.github.io.xpi build/profile/extensions
|
||||
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/i2ppb@eyedeekay.github.io.xpi build/profile/extensions/i2ppb@eyedeekay.github.io.xpi
|
||||
include makefiles/su.mk
|
||||
|
||||
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
|
||||
include makefiles/su-unsigned.mk
|
||||
|
||||
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 ../
|
||||
include makefiles/docker.mk
|
||||
|
||||
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/i2ppb@eyedeekay.github.io.xpi build/app-profile/extensions
|
||||
cp build/HTTPSEverywhere.xpi "build/app-profile/extensions/https-everywhere-eff@eff.org.xpi"
|
||||
cp build/i2ppb@eyedeekay.github.io.xpi build/app-profile/extensions/i2ppb@eyedeekay.github.io.xpi
|
||||
|
||||
build-extensions: build/i2ppb@eyedeekay.github.io.xpi build/NoScript.xpi build/HTTPSEverywhere.xpi
|
||||
|
||||
build/i2ppb@eyedeekay.github.io.xpi: i2psetproxy.url
|
||||
curl -L `cat i2psetproxy.url` > build/i2ppb@eyedeekay.github.io.xpi
|
||||
|
||||
build/NoScript.xpi: NoScript.url
|
||||
curl -L `cat NoScript.url` > build/NoScript.xpi
|
||||
|
||||
build/HTTPSEverywhere.xpi: HTTPSEverywhere.url
|
||||
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/3809748/"`./amo-version.sh https-everywhere`"/https-everywhere-eff@eff.org.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/3887295/"`./amo-version.sh i2p-in-private-browsing`"/i2ppb@eyedeekay.github.io.xpi" > i2psetproxy.url
|
||||
#
|
||||
# TODO: switch to the "Rhizome" variant which has extended permission to do things like set the homepage.
|
||||
# @echo "https://addons.mozilla.org/firefox/downloads/file/3799074/"`./amo-version.sh i2pipb-rhizome-variant`"/i2prhz@eyedeekay.github.io.xpi" > i2psetproxy.url
|
||||
|
||||
|
||||
#https://addons.mozilla.org/firefox/downloads/file/3821635/i2p_in_private_browsing-0.112.1-an+fx.xpi
|
||||
#i2ppb@eyedeekay.github.io.xpi
|
||||
|
||||
build/profile/extensions: build/profile
|
||||
mkdir -p build/profile/extensions
|
||||
|
||||
build/profile: build
|
||||
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:
|
||||
install -D -m644 src/unix/i2pbrowserrc /etc/i2pbrowser/i2pbrowserrc
|
||||
install -D -m644 src/unix/i2pbrowserdebianrc /etc/i2pbrowser/i2pbrowserdebianrc
|
||||
install -D -m755 build/profile/i2pbrowser.sh /usr/local/bin/i2pbrowser
|
||||
install -D -m755 build/app-profile/i2pconfig.sh /usr/local/bin/i2pconfig
|
||||
install -D -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)-signed" -signer "$(SIGNER)" -version "$(I2P_VERSION)"
|
||||
java -cp "$(HOME)/i2p/lib/*" net.i2p.crypto.SU3File sign -c ROUTER -f EXE I2P-Profile-Installer-$(PROFILE_VERSION)-signed.exe I2P-Profile-Installer-$(PROFILE_VERSION)-signed.su3 "$(HOME)/.i2p-plugin-keys/news-su3-keystore.ks" "$(I2P_VERSION)" $(SIGNER)
|
||||
|
||||
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
|
||||
|
||||
orig:
|
||||
tar --exclude=debian --exclude=.git -cvzf ../i2p-firefox-profile_$(PROFILE_VERSION).orig.tar.gz .
|
||||
|
||||
## HOWTO: If you need to release a package to launchpad, build for the oldest
|
||||
## release launchpad supports(bionic AFIACT). Then, after the build is
|
||||
## published, copy it to the other distributions. When bionic is out of date,
|
||||
## update it to the new LTS.
|
||||
|
||||
bionic:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) bionic; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
focal:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) focal; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
groovy:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) groovy; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
buster:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) buster; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
bullseye:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) bullseye; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
trixie:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) trixie; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
sid:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) sid; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
dput:
|
||||
dput --simulate --force ppa:i2p-community/ppa ../i2p-firefox-profile_$(PROFILE_VERSION)-1_source.changes || exit
|
||||
dput --force ppa:i2p-community/ppa ../i2p-firefox-profile_$(PROFILE_VERSION)-1_source.changes
|
||||
|
||||
launchpad: bionic
|
||||
include makefiles/debian.mk
|
||||
|
||||
I2P_DATE=`date +%Y-%m-%d`
|
||||
|
||||
prepupdate:
|
||||
cp -v "I2P-Profile-Installer-$(PROFILE_VERSION)-signed.su3" i2pwinupdate.su3
|
||||
|
||||
i2pwinupdate.su3.torrent: prepupdate
|
||||
mktorrent --announce=http://tracker2.postman.i2p/announce.php --announce=http://w7tpbzncbcocrqtwwm3nezhnnsw4ozadvi2hmvzdhrqzfxfum7wa.b32.i2p/a --announce=http://mb5ir7klpc2tj6ha3xhmrs3mseqvanauciuoiamx2mmzujvg67uq.b32.i2p/a i2pwinupdate.su3
|
||||
|
||||
torrent: i2pwinupdate.su3.torrent
|
||||
|
||||
MAGNET=`bttools torrent printinfo i2pwinupdate.su3.torrent | grep 'MagNet' | sed 's|MagNet: ||g' | sed 's|%3A|:|g'| sed 's|%2F|/|g'`
|
||||
|
||||
releases.json: torrent
|
||||
@echo "[" | tee ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " {" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"date\": \"$(I2P_DATE)\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"version\": \"$(I2P_VERSION)\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"minVersion\": \"1.5.0\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"minJavaVersion\": \"1.8\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"updates\": {" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"su3\": {" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"torrent\": \"$(MAGNET)\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"url\": [" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"http://ekm3fu6fr5pxudhwjmdiea5dovc3jdi66hjgop4c7z7dfaw7spca.b32.i2p/i2pwinupdate.su3\"" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " ]" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo "]" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
MAGNET_TESTING=`bttools torrent printinfo i2pwinupdate-testing.su3.torrent | grep 'MagNet' | sed 's|MagNet: ||g' | sed 's|%3A|:|g'| sed 's|%2F|/|g'`
|
||||
|
||||
BLANK=`awk '! NF { print NR; exit }' changelog.txt`
|
||||
|
||||
I2P.zip: I2P-jpackage-windows-$(I2P_VERSION).zip
|
||||
|
||||
I2P-jpackage-windows-$(I2P_VERSION).zip:
|
||||
zip I2P-jpackage-windows-$(I2P_VERSION).zip -r I2P
|
||||
zip I2P-jpackage-windows-$(I2P_VERSION).zip -r build/I2P
|
||||
|
||||
changelog:
|
||||
head -n "$(BLANK)" changelog.txt
|
||||
|
54
README.md
54
README.md
@ -4,33 +4,41 @@ 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
|
||||
- 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
|
||||
- make
|
||||
- nsis
|
||||
- dos2unix
|
||||
- curl
|
||||
- jq
|
||||
|
||||
to build a Debian package, you'll also need
|
||||
In addition, you will need the NSIS plugin "ShellExecAsUser" which you can get from the
|
||||
[NSIS Wiki Page](https://nsis.sourceforge.io/ShellExecAsUser_plug-in). In order to install
|
||||
the plugin on Debian, Ubuntu, or using `WSL`, you can download the: [7zip release](https://nsis.sourceforge.io/mediawiki/images/6/68/ShellExecAsUser_amd64-Unicode.7z)
|
||||
and copy the content of `Plugins` to `/usr/share/nsis/Plugins`.
|
||||
|
||||
* checkinstall
|
||||
```sh
|
||||
cp -rv Plugins/* /usr/share/nsis/Plugins/
|
||||
```
|
||||
|
||||
To build a Debian package, you'll also need
|
||||
|
||||
- checkinstall
|
||||
|
||||
Preparation
|
||||
-----------
|
||||
|
||||
Before you build, run the targets
|
||||
|
||||
|
||||
make clean-extensions
|
||||
make extensions
|
||||
|
||||
@ -90,8 +98,8 @@ with `sudo service i2p start` then you can run the script:
|
||||
|
||||
/usr/local/bin/i2p-config-service-setup
|
||||
|
||||
Including a jpackaged I2P Router(EXPERIMENTAL)
|
||||
----------------------------------------------
|
||||
Including a jpackaged I2P Router
|
||||
--------------------------------
|
||||
|
||||
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
|
||||
@ -159,6 +167,9 @@ you should select "Checkout as is, commit as is" and leave line-endings alone.
|
||||
End-to-End Windows build process using Cygwin
|
||||
---------------------------------------------
|
||||
|
||||
I highly recommend you look into the Chocolatey package manager, which makes it much
|
||||
easier to configure these tools and keep them up to date.
|
||||
|
||||
**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%`
|
||||
@ -169,27 +180,26 @@ 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`
|
||||
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
|
||||
4. 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 ..
|
||||
|
||||
4. Move into the i2p.firefox directory. Run the `./build.sh` script.
|
||||
5. Move into the i2p.firefox directory. Run the `./build.sh` script.
|
||||
|
||||
cd i2p.firefox
|
||||
./build.sh
|
||||
|
||||
5. Run `make` to build the installer.
|
||||
6. Run `make` to build the installer.
|
||||
|
||||
Doing a Release
|
||||
---------------
|
||||
|
@ -1,4 +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 '"'
|
||||
curl -s "https://addons.mozilla.org/api/v5/addons/addon/$1/versions/?page_size=1" | jq '.results | .[0] | .file | .url' | tr -d '"'
|
||||
|
||||
|
43
build.sh
43
build.sh
@ -1,12 +1,17 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
|
||||
cd "$SCRIPT_DIR" || exit 1
|
||||
|
||||
. i2pversion
|
||||
|
||||
if [ -f i2pversion_override ]; then
|
||||
. i2pversion_override
|
||||
fi
|
||||
|
||||
COUNT="Ten Nine Eight Seven Six Five Four Three Two One"
|
||||
|
||||
JAVA=$(java --version | tr -d 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\n' | cut -d ' ' -f 2 | cut -d '.' -f 1 | tr -d '\n\t\- ')
|
||||
|
||||
if [ "$JAVA" -lt "14" ]; then
|
||||
@ -15,9 +20,8 @@ if [ "$JAVA" -lt "14" ]; then
|
||||
fi
|
||||
if [ "$JAVA" -lt "17" ]; then
|
||||
echo "It is highly recommended that you use Java 17+ to build release packages"
|
||||
sleep 5s
|
||||
fi
|
||||
sleep 2s
|
||||
sleep 5s
|
||||
|
||||
if [ -z "${JAVA_HOME}" ]; then
|
||||
JAVA_HOME=`type -p java|xargs readlink -f|xargs dirname|xargs dirname`
|
||||
@ -28,22 +32,42 @@ echo "cleaning"
|
||||
./clean.sh
|
||||
|
||||
HERE="$PWD"
|
||||
cd "$HERE/../i2p.i2p/"
|
||||
if [ ! -d "$HERE/../i2p.i2p.jpackage-build/" ]; then
|
||||
git clone https://i2pgit.org/i2p-hackers/i2p.i2p "$HERE/../i2p.i2p.jpackage-build/"
|
||||
fi
|
||||
cd "$HERE/../i2p.i2p.jpackage-build/"
|
||||
git checkout "$VERSION"
|
||||
ant distclean preppkg-windows || true
|
||||
for i in $COUNT; do
|
||||
echo -n "$i...."; sleep 1s
|
||||
done
|
||||
ant distclean pkg || 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"
|
||||
I2P_PKG="$HERE/../i2p.i2p.jpackage-build/pkg-temp"
|
||||
RES_DIR="$HERE/../i2p.i2p.jpackage-build/installer/resources"
|
||||
I2P_JARS="$I2P_PKG/lib"
|
||||
I2P_JBIGI="$HERE/../i2p.i2p.jpackage-build/installer/lib/jbigi"
|
||||
|
||||
|
||||
echo "compiling custom launcher"
|
||||
mkdir build
|
||||
cp "$I2P_JARS"/*.jar build
|
||||
if [ ! -f "$HERE/build/jna.jar" ]; then
|
||||
wget -O "$HERE/build/jna.jar" "https://repo1.maven.org/maven2/net/java/dev/jna/jna/$JNA_VERSION/jna-$JNA_VERSION.jar"
|
||||
fi
|
||||
|
||||
if [ ! -f "$HERE/build/jna-platform.jar" ]; then
|
||||
wget -O "$HERE/build/jna-platform.jar" "https://repo1.maven.org/maven2/net/java/dev/jna/jna-platform/$JNA_VERSION/jna-platform-$JNA_VERSION.jar"
|
||||
fi
|
||||
|
||||
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
|
||||
"$JAVA_HOME"/bin/javac -d ../build -classpath "$HERE/build/jna.jar":"$HERE/build/jna-platform.jar":"$HERE/build/i2p.jar":"$HERE/build/router.jar":"$HERE/build/routerconsole.jar" \
|
||||
net/i2p/router/Elevator.java \
|
||||
net/i2p/router/Shell32X.java \
|
||||
net/i2p/router/WinLauncher.java \
|
||||
net/i2p/router/WindowsUpdatePostProcessor.java \
|
||||
net/i2p/router/WinUpdateProcess.java
|
||||
|
||||
cd ..
|
||||
|
||||
#echo "building launcher.jar"
|
||||
@ -65,5 +89,4 @@ echo "preparing to invoke jpackage for I2P version $I2P_VERSION"
|
||||
--java-options "--add-opens java.base/java.nio=ALL-UNNAMED" \
|
||||
$JPACKAGE_OPTS \
|
||||
--resource-dir build \
|
||||
--java-options "--illegal-access=permit" \
|
||||
--input build --main-jar launcher.jar --main-class net.i2p.router.WinLauncher
|
||||
|
@ -1,3 +1,20 @@
|
||||
2022-03-25 idk
|
||||
* This release adds support for user-mode, non-privileged installation of the
|
||||
jpackaged router and the browser profile. Admin installation is still supported
|
||||
and detected automatically, to support existing bundles.
|
||||
* On restart to update, will detect if a router requires admin rights to install
|
||||
and will ask the user to authorize the update. In user-mode, no prompt will ever
|
||||
be seen.
|
||||
* Updates to the Firefox profiles to improve compatibility with more Firefoxes
|
||||
|
||||
2022-02-10 idk
|
||||
* This release fixes automatic update using Bittorrent within the I2P network
|
||||
and the custom Update PostProcessor.
|
||||
* Fixes the first-run launcher bug
|
||||
* Drastically simplifies the Windows build process
|
||||
* Adds support for development releases
|
||||
* Adds support for Debian packaging(Of just the Firefox profile)
|
||||
|
||||
2021-11-1 idk
|
||||
* HTTPS Everywhere will now self-disable on some Firefox versions. This is not
|
||||
an issue since HTTPS Everywhere is deprecated in favor of Firefox built-in
|
||||
|
5
clean.sh
5
clean.sh
@ -1,5 +1,9 @@
|
||||
#! /usr/bin/env sh
|
||||
|
||||
here=$(pwd)
|
||||
cd ../i2p.i2p.jpackage-build/
|
||||
ant distclean
|
||||
cd "$here"
|
||||
rm -rf \
|
||||
build \
|
||||
eventlog.txt \
|
||||
@ -12,6 +16,7 @@ rm -rf \
|
||||
peerProfiles \
|
||||
prngseed.rnd \
|
||||
wrapper.log \
|
||||
*.app \
|
||||
*.jar \
|
||||
*.exe \
|
||||
*.dmg
|
10
i2pversion
10
i2pversion
@ -1,15 +1,17 @@
|
||||
#! /usr/bin/env sh
|
||||
|
||||
JNA_VERSION=5.10.0
|
||||
export JNA_VERSION=5.10.0
|
||||
|
||||
#Comment this out to build from an alternate branch or
|
||||
# the tip of the master branch.
|
||||
I2P_VERSION=1.6.1
|
||||
export I2P_VERSION=1.6.1
|
||||
I2P_VERSION=1.7.0
|
||||
export I2P_VERSION=1.7.0
|
||||
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
|
||||
#I2P_VERSION=1.7.0
|
||||
#export I2P_VERSION=1.7.0
|
||||
#VERSION=master
|
||||
#export VERSION="$VERSION"
|
||||
|
33
java/net/i2p/router/Elevator.java
Normal file
33
java/net/i2p/router/Elevator.java
Normal file
@ -0,0 +1,33 @@
|
||||
package net.i2p.router;
|
||||
|
||||
import com.sun.jna.WString;
|
||||
import com.sun.jna.platform.win32.Kernel32;
|
||||
import com.sun.jna.platform.win32.Kernel32Util;
|
||||
|
||||
public class Elevator {
|
||||
public static void main(String... args) {
|
||||
executeAsAdministrator("c:\\windows\\system32\\notepad.exe", "");
|
||||
}
|
||||
|
||||
public static void executeAsAdministrator(String command, String args) {
|
||||
if (command == "" || command == null) {
|
||||
System.out.println("No command specified");
|
||||
return;
|
||||
}
|
||||
Shell32X.SHELLEXECUTEINFO execInfo = new Shell32X.SHELLEXECUTEINFO();
|
||||
execInfo.lpFile = new WString(command);
|
||||
if (args != null)
|
||||
execInfo.lpParameters = new WString(args);
|
||||
execInfo.nShow = Shell32X.SW_SHOWDEFAULT;
|
||||
execInfo.fMask = Shell32X.SEE_MASK_NOCLOSEPROCESS;
|
||||
execInfo.lpVerb = new WString("runas");
|
||||
boolean result = Shell32X.INSTANCE.ShellExecuteEx(execInfo);
|
||||
|
||||
if (!result) {
|
||||
int lastError = Kernel32.INSTANCE.GetLastError();
|
||||
String errorMessage = Kernel32Util.formatMessageFromLastErrorCode(lastError);
|
||||
throw new RuntimeException("Error performing elevation: " + lastError + ": " + errorMessage + " (apperror="
|
||||
+ execInfo.hInstApp + ")");
|
||||
}
|
||||
}
|
||||
}
|
111
java/net/i2p/router/Shell32X.java
Normal file
111
java/net/i2p/router/Shell32X.java
Normal file
@ -0,0 +1,111 @@
|
||||
package net.i2p.router;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
import com.sun.jna.Native;
|
||||
import com.sun.jna.Pointer;
|
||||
import com.sun.jna.Structure;
|
||||
import com.sun.jna.WString;
|
||||
import com.sun.jna.platform.win32.Shell32;
|
||||
import com.sun.jna.platform.win32.WinDef.HINSTANCE;
|
||||
import com.sun.jna.platform.win32.WinDef.HWND;
|
||||
import com.sun.jna.platform.win32.WinNT.HANDLE;
|
||||
import com.sun.jna.platform.win32.WinReg.HKEY;
|
||||
import com.sun.jna.win32.W32APIOptions;
|
||||
|
||||
public interface Shell32X extends Shell32 {
|
||||
Shell32X INSTANCE = (Shell32X) Native.loadLibrary("shell32", Shell32X.class, W32APIOptions.UNICODE_OPTIONS);
|
||||
|
||||
int SW_HIDE = 0;
|
||||
int SW_MAXIMIZE = 3;
|
||||
int SW_MINIMIZE = 6;
|
||||
int SW_RESTORE = 9;
|
||||
int SW_SHOW = 5;
|
||||
int SW_SHOWDEFAULT = 10;
|
||||
int SW_SHOWMAXIMIZED = 3;
|
||||
int SW_SHOWMINIMIZED = 2;
|
||||
int SW_SHOWMINNOACTIVE = 7;
|
||||
int SW_SHOWNA = 8;
|
||||
int SW_SHOWNOACTIVATE = 4;
|
||||
int SW_SHOWNORMAL = 1;
|
||||
|
||||
/** File not found. */
|
||||
int SE_ERR_FNF = 2;
|
||||
|
||||
/** Path not found. */
|
||||
int SE_ERR_PNF = 3;
|
||||
|
||||
/** Access denied. */
|
||||
int SE_ERR_ACCESSDENIED = 5;
|
||||
|
||||
/** Out of memory. */
|
||||
int SE_ERR_OOM = 8;
|
||||
|
||||
/** DLL not found. */
|
||||
int SE_ERR_DLLNOTFOUND = 32;
|
||||
|
||||
/** Cannot share an open file. */
|
||||
int SE_ERR_SHARE = 26;
|
||||
|
||||
int SEE_MASK_NOCLOSEPROCESS = 0x00000040;
|
||||
|
||||
int ShellExecute(int i, String lpVerb, String lpFile, String lpParameters, String lpDirectory, int nShow);
|
||||
|
||||
boolean ShellExecuteEx(SHELLEXECUTEINFO lpExecInfo);
|
||||
|
||||
public static class SHELLEXECUTEINFO extends Structure {
|
||||
/*
|
||||
* DWORD cbSize;
|
||||
* ULONG fMask;
|
||||
* HWND hwnd;
|
||||
* LPCTSTR lpVerb;
|
||||
* LPCTSTR lpFile;
|
||||
* LPCTSTR lpParameters;
|
||||
* LPCTSTR lpDirectory;
|
||||
* int nShow;
|
||||
* HINSTANCE hInstApp;
|
||||
* LPVOID lpIDList;
|
||||
* LPCTSTR lpClass;
|
||||
* HKEY hkeyClass;
|
||||
* DWORD dwHotKey;
|
||||
* union {
|
||||
* HANDLE hIcon;
|
||||
* HANDLE hMonitor;
|
||||
* } DUMMYUNIONNAME;
|
||||
* HANDLE hProcess;
|
||||
*/
|
||||
|
||||
public int cbSize = size();
|
||||
public int fMask;
|
||||
public HWND hwnd;
|
||||
public WString lpVerb;
|
||||
public WString lpFile;
|
||||
public WString lpParameters;
|
||||
public WString lpDirectory;
|
||||
public int nShow;
|
||||
public HINSTANCE hInstApp;
|
||||
public Pointer lpIDList;
|
||||
public WString lpClass;
|
||||
public HKEY hKeyClass;
|
||||
public int dwHotKey;
|
||||
|
||||
/*
|
||||
* Actually:
|
||||
* union {
|
||||
* HANDLE hIcon;
|
||||
* HANDLE hMonitor;
|
||||
* } DUMMYUNIONNAME;
|
||||
*/
|
||||
public HANDLE hMonitor;
|
||||
public HANDLE hProcess;
|
||||
|
||||
protected List getFieldOrder() {
|
||||
return Arrays.asList(new String[] {
|
||||
"cbSize", "fMask", "hwnd", "lpVerb", "lpFile", "lpParameters",
|
||||
"lpDirectory", "nShow", "hInstApp", "lpIDList", "lpClass",
|
||||
"hKeyClass", "dwHotKey", "hMonitor", "hProcess",
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -1,6 +1,8 @@
|
||||
package net.i2p.router;
|
||||
|
||||
import java.io.*;
|
||||
import java.net.InetAddress;
|
||||
import java.net.Socket;
|
||||
import java.util.*;
|
||||
|
||||
import net.i2p.crypto.*;
|
||||
@ -17,17 +19,17 @@ import static net.i2p.update.UpdateType.*;
|
||||
|
||||
/**
|
||||
* Launches a router from %PROGRAMFILES%/I2P using configuration data in
|
||||
* %LOCALAPPDATA%/I2P.. Uses Java 9 APIs.
|
||||
|
||||
* %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
|
||||
* 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();
|
||||
File programs = selectProgramFile();
|
||||
if (!programs.exists())
|
||||
programs.mkdirs();
|
||||
else if (!programs.isDirectory()) {
|
||||
@ -46,9 +48,16 @@ public class WinLauncher {
|
||||
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"));
|
||||
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());
|
||||
// do a quick check to see of port 7657 is already occupied
|
||||
if (i2pIsRunning()) {
|
||||
System.err.println("I2P is already running");
|
||||
System.exit(0);
|
||||
}
|
||||
|
||||
// wupp.i2pRouter = new Router(System.getProperties());
|
||||
System.out.println("Router is configured");
|
||||
|
||||
Thread registrationThread = new Thread(REGISTER_UPP);
|
||||
@ -56,25 +65,43 @@ public class WinLauncher {
|
||||
registrationThread.setDaemon(true);
|
||||
registrationThread.start();
|
||||
|
||||
wupp.i2pRouter.runRouter();
|
||||
// wupp.i2pRouter.runRouter();
|
||||
RouterLaunch.main(args);
|
||||
}
|
||||
|
||||
private static boolean i2pIsRunning() {
|
||||
// check if there's something listening on port 7657
|
||||
try {
|
||||
InetAddress localhost = InetAddress.getLocalHost();
|
||||
Socket s = new Socket(localhost, 7657);
|
||||
s.close();
|
||||
return true;
|
||||
} catch (IOException e) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
private static final Runnable REGISTER_UPP = () -> {
|
||||
|
||||
// first wait for the RouterContext to appear
|
||||
RouterContext ctx;
|
||||
while ((ctx = (RouterContext) wupp.i2pRouter.getContext().getCurrentContext()) == null) {
|
||||
while ((ctx = (RouterContext) RouterContext.getCurrentContext()) == null) {
|
||||
sleep(1000);
|
||||
}
|
||||
|
||||
// then wait for the update manager
|
||||
ClientAppManager cam = ctx.clientAppManager();
|
||||
|
||||
ClientAppManager cam;
|
||||
while ((cam = ctx.clientAppManager()) == null) {
|
||||
sleep(1000);
|
||||
}
|
||||
|
||||
UpdateManager um;
|
||||
while ((um = (UpdateManager) cam.getRegisteredApp(UpdateManager.APP_NAME)) == null) {
|
||||
sleep(1000);
|
||||
}
|
||||
|
||||
wupp = new WindowsUpdatePostProcessor(ctx);
|
||||
WindowsUpdatePostProcessor wupp = new WindowsUpdatePostProcessor(ctx);
|
||||
um.register(wupp, UpdateType.ROUTER_SIGNED_SU3, SU3File.TYPE_EXE);
|
||||
um.register(wupp, UpdateType.ROUTER_DEV_SU3, SU3File.TYPE_EXE);
|
||||
};
|
||||
@ -88,7 +115,17 @@ public class WinLauncher {
|
||||
}
|
||||
}
|
||||
|
||||
private static File selectHome() { //throws Exception {
|
||||
private static File selectHome() { // throws Exception {
|
||||
String path_override = System.getenv("I2P_CONFIG");
|
||||
if (path_override != null) {
|
||||
File path = new File(path_override);
|
||||
if (path != null && path.exists()) {
|
||||
if (path.isDirectory())
|
||||
return path.getAbsoluteFile();
|
||||
else
|
||||
throw new RuntimeException("I2P_CONFIG is not a directory: " + path);
|
||||
}
|
||||
}
|
||||
if (SystemVersion.isWindows()) {
|
||||
File home = new File(System.getProperty("user.home"));
|
||||
File appData = new File(home, "AppData");
|
||||
@ -105,4 +142,27 @@ public class WinLauncher {
|
||||
}
|
||||
}
|
||||
|
||||
private static File selectProgramFile() {
|
||||
String path_override = System.getenv("I2P");
|
||||
if (path_override != null) {
|
||||
File path = new File(path_override);
|
||||
if (path.exists()) {
|
||||
if (path.isDirectory())
|
||||
return path.getAbsoluteFile();
|
||||
else
|
||||
throw new RuntimeException("I2P is not a directory: " + path);
|
||||
}
|
||||
}
|
||||
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();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -11,20 +11,20 @@ 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{
|
||||
|
||||
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;
|
||||
return null;
|
||||
} else {
|
||||
workDir.mkdirs();
|
||||
}
|
||||
@ -35,37 +35,43 @@ class WinUpdateProcess implements Runnable {
|
||||
|
||||
private void runUpdateInstaller() throws IOException {
|
||||
String version = versionSupplier.get();
|
||||
File file = fileSupplier.get();
|
||||
if (file == null)
|
||||
return;
|
||||
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");
|
||||
if (logFile.canWrite()) {
|
||||
// check if we can write to the log file. If we can, use the ProcessBuilder to
|
||||
// run the installer.
|
||||
ProcessBuilder pb = new ProcessBuilder(file.getAbsolutePath(), "/S", "/D=" + workingDir.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");
|
||||
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) {
|
||||
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.");
|
||||
}
|
||||
} else {
|
||||
// If we cant write to the log file and we're on Windows, use the elevator to
|
||||
// execute the installer instead of the ProcessBuilder.
|
||||
Elevator.executeAsAdministrator(file.getAbsolutePath(), " /S /D=" + workingDir.getAbsolutePath());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
try {
|
||||
runUpdateInstaller();
|
||||
} catch(IOException ioe) {
|
||||
} catch (IOException ioe) {
|
||||
System.out.println("Error running updater, update may fail." + ioe);
|
||||
}
|
||||
}
|
||||
|
@ -5,7 +5,6 @@ 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;
|
||||
@ -18,82 +17,79 @@ 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 Log _log;
|
||||
private final RouterContext ctx;
|
||||
protected static Router i2pRouter = null;
|
||||
|
||||
private final AtomicBoolean hook = new AtomicBoolean();
|
||||
private final String fileName = "i2p-jpackage-update.exe";
|
||||
|
||||
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;
|
||||
this._log = ctx.logManager().getLog(WindowsUpdatePostProcessor.class);
|
||||
}
|
||||
|
||||
public String getVersion() {
|
||||
return version;
|
||||
}
|
||||
|
||||
|
||||
public File getFile() {
|
||||
return positionedFile;
|
||||
}
|
||||
|
||||
public void updateDownloadedandVerified(UpdateType type, int fileType, String version, File file) throws IOException {
|
||||
public void updateDownloadedandVerified(UpdateType type, int fileType, String version, File file)
|
||||
throws IOException {
|
||||
_log.info("Got an update to post-process");
|
||||
if (SystemVersion.isWindows()) {
|
||||
|
||||
if (type != UpdateType.ROUTER_SIGNED_SU3 && type != UpdateType.ROUTER_DEV_SU3) {
|
||||
_log.warn("Unsupported update type " + type);
|
||||
return;
|
||||
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));
|
||||
}
|
||||
|
||||
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) {
|
||||
if (this.ctx != null) {
|
||||
File newFile = new File(workDir(), fileName);
|
||||
boolean renamedStatus = file.renameTo(newFile);
|
||||
if (renamedStatus)
|
||||
return newFile;
|
||||
return newFile;
|
||||
else
|
||||
throw new IOException("WindowsUpdatePostProcesssor unable to move file to working directory, update will fail");
|
||||
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");
|
||||
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");
|
||||
private File workDir() throws IOException {
|
||||
if (this.ctx != null) {
|
||||
File workDir = new File(this.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;
|
||||
return null;
|
||||
} else {
|
||||
workDir.mkdirs();
|
||||
}
|
||||
@ -102,18 +98,4 @@ public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
|
||||
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();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
28
makefiles/app-profile.mk
Normal file
28
makefiles/app-profile.mk
Normal file
@ -0,0 +1,28 @@
|
||||
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
|
||||
|
||||
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 build/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/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi build/https-everywhere-eff@eff.org.xpi build/i2ppb@eyedeekay.github.io.xpi build/app-profile/extensions
|
||||
cp build/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi "build/app-profile/extensions/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||
cp build/https-everywhere-eff@eff.org.xpi "build/app-profile/extensions/https-everywhere-eff@eff.org.xpi"
|
||||
cp build/i2ppb@eyedeekay.github.io.xpi build/app-profile/extensions/i2ppb@eyedeekay.github.io.xpi
|
28
makefiles/build.mk
Normal file
28
makefiles/build.mk
Normal file
@ -0,0 +1,28 @@
|
||||
build/profile/extensions: build/profile
|
||||
mkdir -p build/profile/extensions
|
||||
|
||||
build/profile: build
|
||||
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
|
55
makefiles/debian.mk
Normal file
55
makefiles/debian.mk
Normal file
@ -0,0 +1,55 @@
|
||||
orig:
|
||||
tar --exclude=debian --exclude=.git -cvzf ../i2p-firefox-profile_$(PROFILE_VERSION).orig.tar.gz .
|
||||
|
||||
## HOWTO: If you need to release a package to launchpad, build for the oldest
|
||||
## release launchpad supports(bionic AFIACT). Then, after the build is
|
||||
## published, copy it to the other distributions. When bionic is out of date,
|
||||
## update it to the new LTS.
|
||||
|
||||
bionic:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) bionic; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
focal:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) focal; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
groovy:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) groovy; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
buster:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) buster; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
bullseye:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) bullseye; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
trixie:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) trixie; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
sid:
|
||||
@sed -i "s|`head -n 1 debian/changelog`|i2p-firefox-profile ($(PROFILE_VERSION)-1) sid; urgency=medium|g" debian/changelog
|
||||
make orig
|
||||
debuild -S
|
||||
make dput
|
||||
|
||||
dput:
|
||||
dput --simulate --force ppa:i2p-community/ppa ../i2p-firefox-profile_$(PROFILE_VERSION)-1_source.changes || exit
|
||||
dput --force ppa:i2p-community/ppa ../i2p-firefox-profile_$(PROFILE_VERSION)-1_source.changes
|
||||
|
||||
launchpad: bionic
|
12
makefiles/docker.mk
Normal file
12
makefiles/docker.mk
Normal file
@ -0,0 +1,12 @@
|
||||
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
|
25
makefiles/extensions.mk
Normal file
25
makefiles/extensions.mk
Normal file
@ -0,0 +1,25 @@
|
||||
|
||||
build-extensions: extensions build/i2ppb@eyedeekay.github.io.xpi build/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi build/https-everywhere-eff@eff.org.xpi
|
||||
|
||||
build/i2ppb@eyedeekay.github.io.xpi: i2psetproxy.url
|
||||
curl -L `cat i2psetproxy.url` > build/i2ppb@eyedeekay.github.io.xpi
|
||||
|
||||
build/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi: NoScript.url
|
||||
curl -L `cat NoScript.url` > "build/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||
|
||||
build/https-everywhere-eff@eff.org.xpi: HTTPSEverywhere.url
|
||||
curl -L `cat HTTPSEverywhere.url` > build/https-everywhere-eff@eff.org.xpi
|
||||
|
||||
clean-extensions:
|
||||
rm -fv i2psetproxy.url NoScript.url HTTPSEverywhere.url build/i2ppb@eyedeekay.github.io.xpi build/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi build/https-everywhere-eff@eff.org.xpi
|
||||
|
||||
extensions: HTTPSEverywhere.url NoScript.url i2psetproxy.url
|
||||
|
||||
HTTPSEverywhere.url:
|
||||
@echo `./amo-version.sh https-everywhere` > HTTPSEverywhere.url
|
||||
|
||||
NoScript.url:
|
||||
@echo `./amo-version.sh noscript` > NoScript.url
|
||||
|
||||
i2psetproxy.url:
|
||||
@echo `./amo-version.sh i2p-in-private-browsing` > i2psetproxy.url
|
39
makefiles/install.mk
Normal file
39
makefiles/install.mk
Normal file
@ -0,0 +1,39 @@
|
||||
install:
|
||||
install -D -m644 src/unix/i2pbrowserrc /etc/i2pbrowser/i2pbrowserrc
|
||||
install -D -m644 src/unix/i2pbrowserdebianrc /etc/i2pbrowser/i2pbrowserdebianrc
|
||||
install -D -m755 build/profile/i2pbrowser.sh /usr/local/bin/i2pbrowser
|
||||
install -D -m755 build/app-profile/i2pconfig.sh /usr/local/bin/i2pconfig
|
||||
install -D -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
|
31
makefiles/new-extensions.mk
Normal file
31
makefiles/new-extensions.mk
Normal file
@ -0,0 +1,31 @@
|
||||
|
||||
build-new-extensions: build/i2ppb@eyedeekay.github.io.xpi build/uBlock0@raymondhill.net.xpi build/jsr@javascriptrestrictor.xpi build/onioncbt@eyedeekay.github.io.xpi build/{b86e4813-687a-43e6-ab65-0bde4ab75758}.xpi
|
||||
|
||||
build/uBlock0@raymondhill.net.xpi:
|
||||
curl -L `cat UblockOrigin.url` > build/uBlock0@raymondhill.net.xpi
|
||||
|
||||
build/jsr@javascriptrestrictor.xpi:
|
||||
curl -L `cat JShelter.url` > build/jsr@javascriptrestrictor.xpi
|
||||
|
||||
build/onioncbt@eyedeekay.github.io.xpi:
|
||||
curl -L `cat onioncontainer.url` > build/onioncbt@eyedeekay.github.io.xpi
|
||||
|
||||
build/{b86e4813-687a-43e6-ab65-0bde4ab75758}.xpi:
|
||||
curl -L `cat LocalCDN.url` > build//{b86e4813-687a-43e6-ab65-0bde4ab75758}.xpi
|
||||
|
||||
UBlockOrigin.url:
|
||||
@echo `./amo-version.sh ublock-origin` > UBlockOrigin.url
|
||||
|
||||
JShelter.url:
|
||||
@echo "`./amo-version.sh javascript-restrictor`" > JShelter.url
|
||||
|
||||
onioncontainer.url:
|
||||
@echo `./amo-version.sh onion-in-container-browsing` > onioncontainer.url
|
||||
|
||||
LocalCDN.url:
|
||||
@echo `./amo-version.sh localcdn-fork-of-decentraleyes` > LocalCDN.url
|
||||
|
||||
clean-new-extensions:
|
||||
rm -f UBlockOrigin.url JShelter.url onioncontainer.url LocalCDN.url build/i2ppb@eyedeekay.github.io.xpi build/onioncbt@eyedeekay.github.io.xpi
|
||||
|
||||
new-extensions: UBlockOrigin.url JShelter.url onioncontainer.url LocalCDN.url
|
26
makefiles/profile.mk
Normal file
26
makefiles/profile.mk
Normal file
@ -0,0 +1,26 @@
|
||||
|
||||
profile: build/profile/user.js build/profile/prefs.js build/profile/bookmarks.html build/profile/storage-sync.sqlite copy-xpi
|
||||
|
||||
profile.tgz: .version profile
|
||||
# $(eval PROFILE_VERSION := $(shell cat src/profile/version.txt))
|
||||
@echo "building profile tarball $(PROFILE_VERSION)"
|
||||
sh -c 'ls build/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 ../
|
||||
|
||||
build/profile/user.js: build/profile src/profile/user.js
|
||||
cp src/profile/user.js build/profile/user.js
|
||||
|
||||
build/profile/prefs.js: build/profile src/profile/prefs.js
|
||||
cp src/profile/prefs.js build/profile/prefs.js
|
||||
|
||||
build/profile/bookmarks.html: build/profile src/profile/bookmarks.html
|
||||
cp src/profile/bookmarks.html build/profile/bookmarks.html
|
||||
|
||||
build/profile/storage-sync.sqlite: build/profile src/profile/storage-sync.sqlite
|
||||
cp src/profile/storage-sync.sqlite build/profile/storage-sync.sqlite
|
||||
|
||||
copy-xpi: build/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi build/https-everywhere-eff@eff.org.xpi build/i2ppb@eyedeekay.github.io.xpi build/profile/extensions
|
||||
cp build/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi "build/profile/extensions/{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||
cp build/https-everywhere-eff@eff.org.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
|
35
makefiles/su-unsigned.mk
Normal file
35
makefiles/su-unsigned.mk
Normal file
@ -0,0 +1,35 @@
|
||||
|
||||
prepupdate-unsignedexe:
|
||||
cp -v "I2P-Profile-Installer-$(PROFILE_VERSION).su3" i2pwinupdate-unsignedexe.su3
|
||||
|
||||
su3-unsignedexe: $(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)"
|
||||
java -cp "$(HOME)/i2p/lib/*" net.i2p.crypto.SU3File sign -c ROUTER -f EXE I2P-Profile-Installer-$(PROFILE_VERSION).exe I2P-Profile-Installer-$(PROFILE_VERSION)-signed.su3 "$(HOME)/.i2p-plugin-keys/news-su3-keystore.ks" "$(I2P_VERSION)" $(SIGNER)
|
||||
|
||||
i2pwinupdate-unsignedexe.su3.torrent: prepupdate-unsignedexe su3-unsignedexe
|
||||
mktorrent \
|
||||
--announce=http://tracker2.postman.i2p/announce.php \
|
||||
--announce=http://w7tpbzncbcocrqtwwm3nezhnnsw4ozadvi2hmvzdhrqzfxfum7wa.b32.i2p/a \
|
||||
--announce=http://mb5ir7klpc2tj6ha3xhmrs3mseqvanauciuoiamx2mmzujvg67uq.b32.i2p/a \
|
||||
i2pwinupdate-unsignedexe.su3
|
||||
|
||||
torrent-unsignedexe: i2pwinupdate-unsignedexe.su3.torrent
|
||||
|
||||
testing-releases.json: torrent-unsignedexe
|
||||
mkdir -p ../i2p.newsxml/data/win/testing/
|
||||
@echo "[" | tee ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " {" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"date\": \"$(I2P_DATE)\"," | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"version\": \"$(I2P_VERSION)\"," | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"minVersion\": \"1.5.0\"," | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"minJavaVersion\": \"1.8\"," | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"updates\": {" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"su3\": {" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"torrent\": \"$(MAGNET_TESTING)\"," | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"url\": [" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " \"http://ekm3fu6fr5pxudhwjmdiea5dovc3jdi66hjgop4c7z7dfaw7spca.b32.i2p/i2pwinupdate.su3\"" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " ]" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
||||
@echo "]" | tee -a ../i2p.newsxml/data/win/testing/releases.json
|
41
makefiles/su.mk
Normal file
41
makefiles/su.mk
Normal file
@ -0,0 +1,41 @@
|
||||
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
|
||||
|
||||
prepupdate:
|
||||
cp -v "I2P-Profile-Installer-$(PROFILE_VERSION)-signed.su3" i2pwinupdate.su3
|
||||
|
||||
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)-signed" -signer "$(SIGNER)" -version "$(I2P_VERSION)"
|
||||
java -cp "$(HOME)/i2p/lib/*" net.i2p.crypto.SU3File sign -c ROUTER -f EXE I2P-Profile-Installer-$(PROFILE_VERSION)-signed.exe I2P-Profile-Installer-$(PROFILE_VERSION)-signed.su3 "$(HOME)/.i2p-plugin-keys/news-su3-keystore.ks" "$(I2P_VERSION)" $(SIGNER)
|
||||
|
||||
i2pwinupdate.su3.torrent: prepupdate su3
|
||||
mktorrent \
|
||||
--announce=http://tracker2.postman.i2p/announce.php \
|
||||
--announce=http://w7tpbzncbcocrqtwwm3nezhnnsw4ozadvi2hmvzdhrqzfxfum7wa.b32.i2p/a \
|
||||
--announce=http://mb5ir7klpc2tj6ha3xhmrs3mseqvanauciuoiamx2mmzujvg67uq.b32.i2p/a \
|
||||
i2pwinupdate.su3
|
||||
|
||||
torrent: i2pwinupdate.su3.torrent
|
||||
|
||||
releases.json: torrent
|
||||
@echo "[" | tee ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " {" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"date\": \"$(I2P_DATE)\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"version\": \"$(I2P_VERSION)\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"minVersion\": \"1.5.0\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"minJavaVersion\": \"1.8\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"updates\": {" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"su3\": {" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"torrent\": \"$(MAGNET)\"," | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"url\": [" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " \"http://ekm3fu6fr5pxudhwjmdiea5dovc3jdi66hjgop4c7z7dfaw7spca.b32.i2p/i2pwinupdate.su3\"" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " ]" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo " }" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
||||
@echo "]" | tee -a ../i2p.newsxml/data/win/beta/releases.json
|
@ -1,3 +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
|
||||
router.newsURL=http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news/win/beta/news.su3
|
||||
router.backupNewsURL=http://tc73n4kivdroccekirco7rhgxdg5f3cjvbaapabupeyzrqwv5guq.b32.i2p/win/beta/news.su3
|
||||
|
@ -60,3 +60,4 @@ 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);
|
||||
user_pref("browser.display.use_system_colors", false);
|
@ -1,19 +1,18 @@
|
||||
# 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.
|
||||
/*
|
||||
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:
|
||||
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
|
||||
/*
|
||||
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");
|
||||
@ -106,7 +105,7 @@ 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("browser.startup.homepage", "http://127.0.0.1:7657/home");
|
||||
|
||||
// Privacy-harden and disable irrelevant features.
|
||||
user_pref("app.normandy.api_url", "");
|
||||
@ -222,3 +221,4 @@ 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);
|
||||
user_pref("browser.display.use_system_colors", false);
|
@ -1 +1 @@
|
||||
1.06.1
|
||||
1.07.1
|
||||
|
@ -6,7 +6,7 @@ UniCode true
|
||||
!define DESCRIPTION "This launches Firefox with a browser profile pre-configured to use i2p"
|
||||
!define FIREFOX_MESSAGE "Could not find Firefox. Please point to where you have installed Firefox. If you have not installed Firefox yet, exit this installer and install Firefox, then start this installer again."
|
||||
!define I2P_MESSAGE "Could not find I2P. Please point to where you have installed I2P. If you have not installed I2P yet, exit this installer and install I2P, then start this installer again."
|
||||
!define LAUNCH_TEXT "Launch the i2p browser?"
|
||||
!define LAUNCH_TEXT "Start I2P?"
|
||||
!define LICENSE_TITLE "Many Licenses"
|
||||
!define CONSOLE_URL "http://127.0.0.1:7657/home"
|
||||
|
||||
@ -18,7 +18,7 @@ var FFINSTEXE
|
||||
var FFNONTORINSTEXE
|
||||
var I2PINSTEXE
|
||||
|
||||
|
||||
SetOverwrite on
|
||||
!define FFINSTEXE
|
||||
!define FFNONTORINSTEXE
|
||||
!define FFINSTEXE32 "$PROGRAMFILES32\Mozilla Firefox\"
|
||||
@ -27,6 +27,8 @@ var I2PINSTEXE
|
||||
!define I2PINSTEXE
|
||||
!define I2PINSTEXE32 "$PROGRAMFILES32\i2p"
|
||||
!define I2PINSTEXE64 "$PROGRAMFILES64\i2p"
|
||||
!define I2PINSTEXE_USERMODE "$LOCALAPPDATA\i2p"
|
||||
|
||||
|
||||
!define RAM_NEEDED_FOR_64BIT 0x80000000
|
||||
|
||||
@ -39,7 +41,7 @@ Name "${COMPANYNAME} - ${APPNAME}"
|
||||
Icon ui2pbrowser_icon.ico
|
||||
OutFile "I2P-Profile-Installer-${VERSIONMAJOR}.${VERSIONMINOR}.${VERSIONBUILD}.exe"
|
||||
|
||||
RequestExecutionLevel admin
|
||||
RequestExecutionLevel user
|
||||
|
||||
!include LogicLib.nsh
|
||||
!include x64.nsh
|
||||
@ -144,45 +146,57 @@ Page instfiles
|
||||
!include i2pbrowser-mozcompat.nsi
|
||||
|
||||
Function .onInit
|
||||
StrCpy $I2PINSTEXE "${I2PINSTEXE64}"
|
||||
UserInfo::GetAccountType
|
||||
pop $0
|
||||
${If} $0 != "admin"
|
||||
StrCpy $INSTDIR "$LOCALAPPDATA\${COMPANYNAME}\${APPNAME}"
|
||||
StrCpy $I2PINSTEXE "${I2PINSTEXE_USERMODE}"
|
||||
${EndIf}
|
||||
!insertmacro MUI_LANGDLL_DISPLAY
|
||||
Call ShouldInstall64Bit
|
||||
${If} $0 == 1
|
||||
${If} ${FileExists} "${FFINSTEXE64}/firefox.exe"
|
||||
${If} ${FileExists} "${FFINSTEXE64}\firefox.exe"
|
||||
StrCpy $FFINSTEXE "${FFINSTEXE64}"
|
||||
StrCpy $FFNONTORINSTEXE "${FFINSTEXE64}"
|
||||
${ElseIf} ${FileExists} "${FFINSTEXE32}/firefox.exe"
|
||||
${ElseIf} ${FileExists} "${FFINSTEXE32}\firefox.exe"
|
||||
StrCpy $FFINSTEXE "${FFINSTEXE32}"
|
||||
StrCpy $FFNONTORINSTEXE "${FFINSTEXE32}"
|
||||
${EndIf}
|
||||
${If} ${FileExists} "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/"
|
||||
${If} ${FileExists} "$PROFILE\OneDrive\Desktop\Tor Browser\Browser\firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE\OneDrive\Desktop\Tor Browser\Browser\"
|
||||
${EndIf}
|
||||
${If} ${FileExists} "$PROFILE/Desktop/Tor Browser/Browser/firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE/Desktop/Tor Browser/Browser/"
|
||||
${If} ${FileExists} "$PROFILE\Desktop\Tor Browser\Browser\firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE\Desktop\Tor Browser\Browser\"
|
||||
${EndIf}
|
||||
${Else}
|
||||
${If} ${FileExists} "${FFINSTEXE32}/firefox.exe"
|
||||
${If} ${FileExists} "${FFINSTEXE32}\firefox.exe"
|
||||
StrCpy $FFINSTEXE "${FFINSTEXE32}"
|
||||
StrCpy $FFNONTORINSTEXE "${FFINSTEXE32}"
|
||||
${EndIf}
|
||||
${If} ${FileExists} "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE/OneDrive/Desktop/Tor Browser/Browser/"
|
||||
${If} ${FileExists} "$PROFILE\OneDrive\Desktop\Tor Browser\Browser\firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE\OneDrive\Desktop\Tor Browser\Browser\"
|
||||
${EndIf}
|
||||
${If} ${FileExists} "$PROFILE/Desktop/Tor Browser/Browser/firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE/Desktop/Tor Browser/Browser/"
|
||||
${If} ${FileExists} "$PROFILE\Desktop\Tor Browser\Browser\firefox.exe"
|
||||
StrCpy $FFINSTEXE "$PROFILE\Desktop\Tor Browser\Browser\"
|
||||
${EndIf}
|
||||
${EndIf}
|
||||
StrCpy $I2PINSTEXE "${I2PINSTEXE64}"
|
||||
${If} ${FileExists} "${I2PINSTEXE32}\i2p.exe"
|
||||
StrCpy $I2PINSTEXE "${I2PINSTEXE32}"
|
||||
${EndIf}
|
||||
${If} ${FileExists} "${I2PINSTEXE64}\i2p.exe"
|
||||
UserInfo::GetAccountType
|
||||
pop $0
|
||||
${If} $0 == "admin"
|
||||
StrCpy $I2PINSTEXE "${I2PINSTEXE64}"
|
||||
${If} ${FileExists} "${I2PINSTEXE32}\i2p.exe"
|
||||
StrCpy $I2PINSTEXE "${I2PINSTEXE32}"
|
||||
${EndIf}
|
||||
${If} ${FileExists} "${I2PINSTEXE64}\i2p.exe"
|
||||
StrCpy $I2PINSTEXE "${I2PINSTEXE64}"
|
||||
${EndIf}
|
||||
${EndIf}
|
||||
# look for user installs
|
||||
FunctionEnd
|
||||
|
||||
Function firefoxDetect
|
||||
${If} ${FileExists} "$FFINSTEXE/firefox.exe"
|
||||
${If} ${FileExists} "$FFINSTEXE\firefox.exe"
|
||||
Abort directory
|
||||
${EndIf}
|
||||
FunctionEnd
|
||||
@ -194,30 +208,12 @@ Function routerDetect
|
||||
createDirectory $I2PINSTEXE
|
||||
SetOutPath $I2PINSTEXE
|
||||
File /nonfatal /a /r "I2P\"
|
||||
File /nonfatal /a /r "I2P\I2P.exe"
|
||||
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\"
|
||||
File /nonfatal /a /r "I2P/config/*"
|
||||
|
||||
Abort directory
|
||||
${EndIf}
|
||||
@ -251,18 +247,8 @@ Section Install
|
||||
|
||||
createDirectory "$I2PINSTEXE\"
|
||||
SetOutPath "$I2PINSTEXE\"
|
||||
File /nonfatal /a /r "I2P/config/*"
|
||||
|
||||
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}
|
||||
${Else}
|
||||
File /nonfatal /a /r "I2P\"
|
||||
@ -270,66 +256,30 @@ Section Install
|
||||
|
||||
createDirectory "$I2PINSTEXE\"
|
||||
SetOutPath "$I2PINSTEXE\"
|
||||
File /nonfatal /a /r "I2P/config/*"
|
||||
|
||||
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"
|
||||
createDirectory "$INSTDIR"
|
||||
SetOutPath "$INSTDIR"
|
||||
File win/i2pbrowser.bat
|
||||
File win/i2pbrowser-private.bat
|
||||
File win/i2pconfig.bat
|
||||
File "win/*"
|
||||
|
||||
# Install the licenses
|
||||
createDirectory "$INSTDIR\licenses"
|
||||
SetOutPath "$INSTDIR\licenses"
|
||||
File /r licenses\*.*
|
||||
File /a /r "licenses/*"
|
||||
|
||||
# Install the profile
|
||||
createDirectory "$INSTDIR\firefox.profile.i2p"
|
||||
SetOutPath "$INSTDIR\firefox.profile.i2p"
|
||||
File profile\user.js
|
||||
File profile\prefs.js
|
||||
File profile\bookmarks.html
|
||||
File profile\storage-sync.sqlite
|
||||
|
||||
# Install the extensions
|
||||
createDirectory "$INSTDIR\firefox.profile.i2p\extensions"
|
||||
SetOutPath "$INSTDIR\firefox.profile.i2p\extensions"
|
||||
File "profile\extensions\{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||
File profile\extensions\https-everywhere-eff@eff.org.xpi
|
||||
File profile\extensions\i2ppb@eyedeekay.github.io.xpi
|
||||
File /a /r "profile/*"
|
||||
|
||||
# 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\i2ppb@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
|
||||
File /a /r "app-profile/*"
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
createDirectory "$SMPROGRAMS\${APPNAME}"
|
||||
@ -349,6 +299,9 @@ Section Install
|
||||
FileWrite $0 "routerconsole.browser=$\"$INSTDIR\i2pconfig.bat$\""
|
||||
FileWriteByte $0 "13"
|
||||
FileWriteByte $0 "10"
|
||||
FileWrite $0 "router.disableTunnelTesting=false"
|
||||
FileWriteByte $0 "13"
|
||||
FileWriteByte $0 "10"
|
||||
FileClose $0
|
||||
|
||||
SetShellVarContext current
|
||||
@ -366,6 +319,9 @@ Section Install
|
||||
createDirectory "$I2PAPPDATA"
|
||||
SetOutPath "$I2PAPPDATA"
|
||||
|
||||
IfFileExists "$LOCALAPPDATA\I2P\eepsite\docroot" +2 0
|
||||
File /nonfatal /a /r "I2P\eepsite"
|
||||
|
||||
;# Point the browser config setting in the working config
|
||||
FileOpen $0 "$I2PAPPDATA\router.config" a
|
||||
FileSeek $0 0 END
|
||||
@ -374,6 +330,9 @@ Section Install
|
||||
FileWrite $0 "routerconsole.browser=$\"$INSTDIR\i2pconfig.bat$\""
|
||||
FileWriteByte $0 "13"
|
||||
FileWriteByte $0 "10"
|
||||
FileWrite $0 "router.disableTunnelTesting=false"
|
||||
FileWriteByte $0 "13"
|
||||
FileWriteByte $0 "10"
|
||||
FileClose $0
|
||||
|
||||
createDirectory "$I2PINSTEXE"
|
||||
@ -392,7 +351,7 @@ SectionEnd
|
||||
Section "uninstall"
|
||||
|
||||
# Remove the licenses
|
||||
rmDir /r "$INSTDIR\licenses"
|
||||
rmDir /r "$INSTDIR\"
|
||||
|
||||
# Uninstall the launcher scripts
|
||||
Delete $INSTDIR\i2pbrowser.bat
|
||||
@ -400,31 +359,13 @@ Section "uninstall"
|
||||
Delete $INSTDIR\i2pbrowser-private.bat
|
||||
Delete $INSTDIR\ui2pbrowser_icon.ico
|
||||
|
||||
# Uninstall the profile
|
||||
Delete $INSTDIR\firefox.profile.i2p\prefs.js
|
||||
Delete $INSTDIR\firefox.profile.i2p\user.js
|
||||
Delete $INSTDIR\firefox.profile.i2p\bookmarks.html
|
||||
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
|
||||
Delete "$INSTDIR\firefox.profile.i2p\extensions\{73a6fe31-595d-460b-a920-fcc0f8843232}.xpi"
|
||||
Delete "$INSTDIR\firefox.profile.i2p\extensions\https-everywhere-eff@eff.org.xpi"
|
||||
Delete "$INSTDIR\firefox.profile.i2p\extensions\i2ppb@eyedeekay.github.io.xpi"
|
||||
|
||||
Delete "$INSTDIR\firefox.profile.config.i2p\extensions\https-everywhere-eff@eff.org.xpi"
|
||||
Delete "$INSTDIR\firefox.profile.config.i2p\extensions\i2ppb@eyedeekay.github.io.xpi"
|
||||
|
||||
Delete "$INSTDIR\firefox.profile.config.i2p\config\userChrome.css"
|
||||
|
||||
# Remove shortcuts and folders
|
||||
Delete "$SMPROGRAMS\${APPNAME}\${APPNAME}.lnk"
|
||||
Delete "$SMPROGRAMS\${APPNAME}\Private Browsing-${APPNAME}.lnk"
|
||||
Delete "$SMPROGRAMS\Uninstall-${APPNAME}.lnk"
|
||||
Delete "$SMPROGRAMS\${APPNAME}\Browse I2P.lnk"
|
||||
Delete "$DESKTOP\Browse I2P - Temporary Identity.lnk"
|
||||
Delete "$DESKTOP\Browse I2P.lnk"
|
||||
Delete "$DESKTOP\${APPNAME}.lnk"
|
||||
Delete "$DESKTOP\Private Browsing-${APPNAME}.lnk"
|
||||
rmDir "$SMPROGRAMS\${APPNAME}"
|
||||
@ -452,9 +393,9 @@ Function LaunchLink
|
||||
${If} ${Silent}
|
||||
ReadEnvStr $0 RESTART_I2P
|
||||
${If} $0 != ""
|
||||
Exec "$INSTDIR\i2pbrowser.bat"
|
||||
ShellExecAsUser::ShellExecAsUser "open" "$DESKTOP\Browse I2P.lnk"
|
||||
${EndIf}
|
||||
${Else}
|
||||
Exec "$INSTDIR\i2pbrowser.bat"
|
||||
ShellExecAsUser::ShellExecAsUser "open" "$DESKTOP\Browse I2P.lnk"
|
||||
${EndIf}
|
||||
FunctionEnd
|
||||
|
@ -1 +1 @@
|
||||
!define I2P_VERSION 1.6.1
|
||||
!define I2P_VERSION 1.7.0
|
||||
|
@ -1,3 +1,3 @@
|
||||
!define VERSIONMAJOR 1
|
||||
!define VERSIONMINOR 06
|
||||
!define VERSIONBUILD 1
|
||||
!define VERSIONMINOR 07
|
||||
!define VERSIONBUILD 3
|
||||
|
@ -58,3 +58,5 @@ 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);
|
||||
user_pref("browser.privatebrowsing.autostart", false);
|
||||
user_pref("browser.display.use_system_colors", false);
|
@ -1,19 +1,18 @@
|
||||
# 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.
|
||||
/*
|
||||
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:
|
||||
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
|
||||
/*
|
||||
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");
|
||||
@ -83,6 +82,9 @@ user_pref("extensions.torbutton.use_nontor_proxy", true);
|
||||
//user_pref("extensions.torlauncher.socks_port_use_ipc", );
|
||||
//user_pref("extensions.torlauncher.socks_ipc_path", "");
|
||||
|
||||
// TODO: this is a Tor Browser specific setting which is ignored on Firefox. If
|
||||
// I make it true, the SOCKS outproxy will have something to connect to. But I
|
||||
// need to test more to find out if that's prudent.
|
||||
user_pref("extensions.torlauncher.start_tor", false);
|
||||
//user_pref("extensions.torlauncher.default_bridge_type", "");
|
||||
user_pref("extensions.torlauncher.prompt_at_startup", false);
|
||||
@ -106,7 +108,7 @@ 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("browser.startup.homepage", "http://127.0.0.1:7657/home");
|
||||
|
||||
// Privacy-harden and disable irrelevant features.
|
||||
user_pref("app.normandy.api_url", "");
|
||||
@ -222,3 +224,5 @@ 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);
|
||||
user_pref("browser.privatebrowsing.autostart", false);
|
||||
user_pref("browser.display.use_system_colors", false);
|
@ -1 +1 @@
|
||||
1.06.1
|
||||
1.07.1
|
||||
|
@ -9,7 +9,13 @@ if exist "%ProgramFiles(x86)%\I2P" (
|
||||
set "I2PPath=%ProgramFiles(x86)%\I2P"
|
||||
)
|
||||
|
||||
if exist "%ProgramFiles%\I2P\jpackaged" (
|
||||
set "I2PPath=%LocalAppData%\I2P\"
|
||||
if exist "%LocalAppData%\I2P\I2P.exe" (
|
||||
set "I2PPath=%LocalAppData%\I2P\"
|
||||
)
|
||||
|
||||
if exist "%I2PPath%\jpackaged" (
|
||||
cd "%LOCALAPPDATA%\I2P"
|
||||
start "i2p" /D "%LOCALAPPDATA%\I2P" "%I2PPath%\i2p.exe"
|
||||
) else (
|
||||
start "i2p" "%I2PPath%\i2p.exe"
|
||||
@ -19,12 +25,15 @@ 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"
|
||||
xcopy /s /i /y "%I2PPath%\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"
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.i2p" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p"
|
||||
)
|
||||
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.i2p\user.js" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\user.js"
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.i2p\prefs.js" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\prefs.js"
|
||||
|
||||
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
|
||||
|
@ -9,7 +9,13 @@ if exist "%ProgramFiles(x86)%\I2P" (
|
||||
set "I2PPath=%ProgramFiles(x86)%\I2P"
|
||||
)
|
||||
|
||||
if exist "%ProgramFiles%\I2P\jpackaged" (
|
||||
set "I2PPath=%LocalAppData%\I2P\"
|
||||
if exist "%LocalAppData%\I2P\I2P.exe" (
|
||||
set "I2PPath=%LocalAppData%\I2P\"
|
||||
)
|
||||
|
||||
if exist "%I2PPath%\jpackaged" (
|
||||
cd "%LOCALAPPDATA%\I2P"
|
||||
start "i2p" /D "%LOCALAPPDATA%\I2P" "%I2PPath%\i2p.exe"
|
||||
) else (
|
||||
start "i2p" "%I2PPath%\i2p.exe"
|
||||
@ -19,12 +25,15 @@ 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"
|
||||
xcopy /s /i /y "%I2PPath%\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"
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.i2p" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p"
|
||||
)
|
||||
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.i2p\user.js" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\user.js"
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.i2p\prefs.js" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.i2p\prefs.js"
|
||||
|
||||
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
|
||||
|
@ -1,13 +1,43 @@
|
||||
@echo off
|
||||
@echo on
|
||||
|
||||
set "I2PPath=%ProgramFiles%\I2P\"
|
||||
if exist "%ProgramFiles%\I2P\" (
|
||||
set "I2PPath=%ProgramFiles%\I2P\"
|
||||
)
|
||||
|
||||
if exist "%ProgramFiles(x86)%\I2P" (
|
||||
set "I2PPath=%ProgramFiles(x86)%\I2P"
|
||||
)
|
||||
|
||||
set "I2PPath=%LocalAppData%\I2P\"
|
||||
if exist "%LocalAppData%\I2P\I2P.exe" (
|
||||
set "I2PPath=%LocalAppData%\I2P\"
|
||||
)
|
||||
|
||||
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"
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.config.i2p\extensions" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p\extensions"
|
||||
) else (
|
||||
echo "configuring profile"
|
||||
xcopy /s /i /y "$INSTDIR\firefox.profile.config.i2p" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p"
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\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
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.config.i2p\user.js" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p\user.js"
|
||||
xcopy /s /i /y "%I2PPath%\I2PBrowser-Launcher\firefox.profile.config.i2p\prefs.js" "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p\prefs.js"
|
||||
|
||||
if exist "%ProgramFiles%\Mozilla Firefox\firefox.exe" (
|
||||
start "i2pbrowser" "%ProgramFiles%\Mozilla Firefox\firefox.exe" -no-remote -profile "%LOCALAPPDATA%\I2PBrowser-Launcher\firefox.profile.config.i2p" -url %1
|
||||
exit
|
||||
)
|
||||
|
||||
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.config.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.config.i2p" -url %1
|
||||
exit
|
||||
)
|
||||
|
||||
exit
|
||||
|
Reference in New Issue
Block a user