Compare commits

...

240 Commits

Author SHA1 Message Date
d013060249 fix URL
Some checks failed
Sync Primary Repository to GitHub Mirror / sync (push) Has been cancelled
Java 22 CI / nsis-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagexe-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagmsi-jdk22 (push) Has been cancelled
Java 22 CI / buildzip-jdk22 (push) Has been cancelled
Java 22 CI / buildtgz-jdk22 (push) Has been cancelled
Java CI / nsis (push) Has been cancelled
Java CI / buildjpackagexe (push) Has been cancelled
Java CI / buildjpackagmsi (push) Has been cancelled
Java CI / buildzip (push) Has been cancelled
Java CI / buildtgz (push) Has been cancelled
Nightly Release / build (push) Has been cancelled
Nightly 22 Release / build (push) Has been cancelled
2025-06-05 17:06:58 -04:00
1e19c61d8c Trigger a build with the new i2p.firefox for testing before taggins
Some checks failed
Sync Primary Repository to GitHub Mirror / sync (push) Has been cancelled
Java 22 CI / nsis-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagexe-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagmsi-jdk22 (push) Has been cancelled
Java 22 CI / buildzip-jdk22 (push) Has been cancelled
Java 22 CI / buildtgz-jdk22 (push) Has been cancelled
Java CI / nsis (push) Has been cancelled
Java CI / buildjpackagexe (push) Has been cancelled
Java CI / buildjpackagmsi (push) Has been cancelled
Java CI / buildzip (push) Has been cancelled
Java CI / buildtgz (push) Has been cancelled
Nightly Release / build (push) Has been cancelled
Nightly 22 Release / build (push) Has been cancelled
2025-06-05 14:37:33 -04:00
48d08076f7 Trigger a build with the new i2p.firefox for testing before taggins
Some checks failed
Java 22 CI / nsis-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagexe-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagmsi-jdk22 (push) Has been cancelled
Java 22 CI / buildzip-jdk22 (push) Has been cancelled
Java 22 CI / buildtgz-jdk22 (push) Has been cancelled
Java CI / nsis (push) Has been cancelled
Java CI / buildjpackagexe (push) Has been cancelled
Java CI / buildjpackagmsi (push) Has been cancelled
Java CI / buildzip (push) Has been cancelled
Java CI / buildtgz (push) Has been cancelled
Nightly Release / build (push) Has been cancelled
Nightly 22 Release / build (push) Has been cancelled
Sync Primary Repository to GitHub Mirror / sync (push) Has been cancelled
2025-06-05 14:15:11 -04:00
8c7ad5a905 Add github sync for i2p.firefox
Some checks failed
Java 22 CI / buildtgz-jdk22 (push) Failing after 1m5s
Java CI / buildtgz (push) Failing after 56s
Nightly Release / build (push) Failing after 22m21s
Nightly 22 Release / build (push) Failing after 20m15s
Java 22 CI / nsis-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagexe-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagmsi-jdk22 (push) Has been cancelled
Java 22 CI / buildzip-jdk22 (push) Has been cancelled
Java CI / nsis (push) Has been cancelled
Java CI / buildjpackagexe (push) Has been cancelled
Java CI / buildjpackagmsi (push) Has been cancelled
Java CI / buildzip (push) Has been cancelled
Sync Primary Repository to GitHub Mirror / sync (push) Has been cancelled
2025-05-10 18:55:30 -04:00
7165629f52 disable git sync job
Some checks failed
Java 22 CI / nsis-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagexe-jdk22 (push) Has been cancelled
Java 22 CI / buildjpackagmsi-jdk22 (push) Has been cancelled
Java 22 CI / buildzip-jdk22 (push) Has been cancelled
Java 22 CI / buildtgz-jdk22 (push) Has been cancelled
Java CI / nsis (push) Has been cancelled
Java CI / buildjpackagexe (push) Has been cancelled
Java CI / buildjpackagmsi (push) Has been cancelled
Java CI / buildzip (push) Has been cancelled
Java CI / buildtgz (push) Has been cancelled
Nightly Release / build (push) Has been cancelled
Nightly 22 Release / build (push) Has been cancelled
2025-04-27 00:12:03 -04:00
4c28feea8c build with new profile 2025-03-20 19:01:24 -04:00
8a22bb8277 test build 2025-02-11 22:25:28 -05:00
56b3317184 test build 2025-02-11 21:43:24 -05:00
de8420c5b2 test build 2025-02-11 21:08:41 -05:00
80dfa2498c test build 2025-02-11 20:51:51 -05:00
a60da07d5a bump version 2025-02-11 14:16:37 -05:00
ccd2edbc20 Fix release redownload script 2024-10-20 15:57:07 -04:00
5a2143a5b0 Update release notes 2024-10-19 14:02:40 -04:00
87e4b3d0d6 Get ready for 2.7.0 2024-10-19 14:00:03 -04:00
e50c862903 pick a release version for nightly master builds 2024-08-26 19:56:32 -04:00
3050624b81 pick a release version for nightly master builds 2024-08-26 19:41:56 -04:00
e1cbbbf284 pick a release version for nightly master builds 2024-08-26 19:34:10 -04:00
1a18d38522 pick a release version for nightly master builds 2024-08-26 19:24:01 -04:00
78ad39e142 only derive profile tag from i2p tag if it exists 2024-08-26 19:10:20 -04:00
919be083e1 tag master builds as master not as numbered version 2024-08-26 19:01:40 -04:00
3d48629a40 If tags are absent, pull from master, so nightlies are really nightlies 2024-08-26 18:53:24 -04:00
5f9df2cb9a If tags are absent, pull from master, so nightlies are really nightlies 2024-08-26 18:50:33 -04:00
a1f093f0b0 use I2P_VERSION not GITHUB_TAG for CI builds 2024-08-26 18:40:02 -04:00
55e10a1633 update release notes 2024-08-26 18:18:16 -04:00
0f470f08ff update release notes 2024-08-26 18:16:07 -04:00
1ea7ccb671 Add jpackage archives and prebuilt jpackage to CI 2024-08-26 18:05:57 -04:00
e3e9d71f62 make the i2pversion script output the version that we're actually building 2024-08-22 23:39:44 -04:00
d2cb4e7dac Bump i2pfirefox version 2024-08-22 23:37:54 -04:00
d3bc6ffc89 Remove redundant whitespace 2024-08-01 17:04:29 -04:00
0c7e4a9fd6 Remove redundant functions 2024-08-01 17:03:11 -04:00
0f271a9013 bump version 2024-07-20 22:40:25 -04:00
a01b11ecb0 bump version 2024-07-20 22:08:57 -04:00
0eea4f9fcb wait longer and re-trigger 2024-07-17 14:34:47 -04:00
acb936a675 fix wrong name 2024-07-16 19:40:32 -04:00
45f64db3cd fix wrong name 2024-07-16 19:09:52 -04:00
3769d7a74c separate out the release-nightly-latest job 2024-07-16 16:35:26 -04:00
45873071fb separate out the release-nightly-latest job 2024-07-16 15:28:38 -04:00
a96502d5c1 add 22 builds to nightly releases 2024-07-16 15:23:24 -04:00
83d02cf379 Change name of build task for jdk22 builds 2024-07-16 15:10:27 -04:00
1463e62c2a Continuously build jdk22 builds 2024-07-16 14:58:51 -04:00
1611312f25 find a writable directory when we're a snap 2024-06-27 02:16:14 -04:00
1e4d327ca2 find a writable directory when we're a snap 2024-06-27 02:15:35 -04:00
045c6dbfbd fix the eepsite directory also
Some checks failed
Java CI / nsis (push) Has been cancelled
Java CI / buildjpackagexe (push) Has been cancelled
Java CI / buildjpackagmsi (push) Has been cancelled
Java CI / buildzip (push) Has been cancelled
Java CI / buildtgz (push) Has been cancelled
Nightly Release / build (push) Has been cancelled
2024-06-27 00:01:05 -04:00
e13156005f Fix plugin path so it works everywhere 2024-06-26 23:16:23 -04:00
1a3d0743ab Fix plugin path so it works everywhere 2024-06-26 21:39:58 -04:00
a41a4824fe Work on a wine build 2024-06-26 21:34:46 -04:00
093ac9fe5d Always make Nightly also Latest 2024-06-26 21:23:35 -04:00
855887da6b Update nightly release text 2024-06-26 20:53:55 -04:00
9ecd701462 Update nightly release text 2024-06-26 20:53:35 -04:00
66f77fec8d Allow replacing nightly releases 2024-06-26 20:50:26 -04:00
8471360a63 Rename nightly release jobs 2024-06-26 20:24:28 -04:00
c006fb0ca8 Set up nightly releases 2024-06-26 20:23:12 -04:00
39a457d314 Fix the build 2024-06-26 19:59:56 -04:00
216f075f32 Remove CCD.java from compile step 2024-06-26 19:33:50 -04:00
4d3e700ec3 Remove some redundant methods 2024-06-26 19:27:29 -04:00
0fc103b777 Only postman tracker in bundle torrent 2024-05-15 23:06:02 -04:00
e7ff841eb5 Bump build number 2024-05-15 21:24:26 -04:00
a4ce1b9a8b Update version 2024-05-07 14:04:08 -04:00
021c1cd1ba Fix CI files 2024-04-29 20:49:51 -04:00
d06a8bb4bf fix CI sync file 2024-04-29 20:28:31 -04:00
95c045e97c Bump version 2024-04-29 20:25:19 -04:00
3047f70164 Sync using github CI 2024-04-29 20:11:39 -04:00
c53baa20e9 Buildscript fixup 2024-04-29 20:09:51 -04:00
a51e878877 update release notes 2024-04-08 19:02:35 -04:00
9f5536e270 sync firefox version with I2P version 2024-04-08 18:48:46 -04:00
2234e5d9d1 update release notes 2024-03-22 14:26:13 -04:00
93962505c7 change name to TAG_VERSION, hyphenate 2024-03-22 14:23:34 -04:00
0603ecf99a specify version based on tag for dev builds based on trunk routers 2024-03-22 14:14:41 -04:00
5e698b3b74 Don't try to automatically insert HTML content 2024-03-20 15:49:23 -04:00
cc55bd0169 fix tag in upload script 2024-03-20 15:07:44 -04:00
7f47018cbf Assure exe is downloaded before generating release torrent 2024-03-20 15:04:44 -04:00
570add3b6f update profile manager version 2024-03-20 13:33:58 -04:00
0e14574aed page generation update for: 2024-03-20 13:05:26.624594558 -0400 EDT m=+193.524147205 2024-03-20 13:05:26 -04:00
599f3499bd sparse checkout requires a newline 2024-03-20 12:51:21 -04:00
4246f60930 Add release notes to release CI description 2024-03-20 12:27:53 -04:00
601b1db8d5 Update how release notes are posted 2024-03-20 12:02:43 -04:00
c47b7c0f76 use I2P's mktorrent when generating the torrent. use the news.sh script to generate torrent based on the tag. 2024-03-20 00:53:45 -04:00
d4cc7dcfdf Generate news from markdown file 2024-03-19 23:44:01 -04:00
58a7ce4fd4 use latest I2P version if tags aren't available 2024-03-19 22:26:34 -04:00
f8870cd12d use the tag to determine the version to build 2024-03-19 21:41:40 -04:00
aff0563fc3 use the tag to determine the version to build 2024-03-19 21:40:14 -04:00
6d460a9042 WindowsAppUtil and WindowsServiceUtil now do not have references to I2P itself 2024-03-19 20:37:08 -04:00
8809ddaac7 Delete redundant sections from the README.md 2024-03-18 10:30:13 -04:00
958f33db7f Delete ancient sections from when I made this useful as a browser profile launcher for Linux 2024-03-18 10:28:39 -04:00
0bfeaaf841 Give the README.md a canned update about how to use the CI description as the basis for a dev build 2024-03-18 10:27:14 -04:00
134ebeb1d0 sleep 20 minutes for release artifacts 2024-03-12 23:55:40 -04:00
b4a3691aae list outputs non-recursively, only directories, only first 2 levels 2024-03-12 23:20:57 -04:00
03748e0c0e list outputs 2024-03-12 22:54:03 -04:00
d4a40e8c86 Fix 7z command 2024-03-12 22:37:46 -04:00
d38fadc902 get 7z help for version 2024-03-12 22:16:18 -04:00
dbb865603a figure out where install ca-certificates 2024-03-12 21:58:22 -04:00
456b26a860 figure out where wsl keeps 7zip 2024-03-12 21:35:10 -04:00
62284056c3 figure out where wsl keeps 7zip 2024-03-12 21:30:02 -04:00
41c06c821c use 7zip when unpacking TBB into Portable 2024-03-12 21:19:31 -04:00
d32c850ede use relative path when calling wsl 2024-03-12 21:14:06 -04:00
f5f4d1c014 use 7zip to unzip for portable 2024-03-12 20:18:19 -04:00
4ad846d151 Switch to WSL for part of the zip script 2024-03-12 19:58:16 -04:00
6dfeaded43 Rename WUPP 2024-03-12 19:52:20 -04:00
57b500a614 Increase i2p.plugins.firefox version 2024-03-10 00:58:54 -05:00
078e542ef0 Delete redundant shortcuts 2024-03-09 23:13:19 -05:00
81d81adc4c no more self-relaunch! 2024-03-08 22:48:24 -05:00
b82986ccf4 set properties in constructor 2024-03-08 22:00:46 -05:00
4ef50bb85a set properties in constructor 2024-03-08 21:35:50 -05:00
b8809bed47 i2pRouter in WinLauncher can't be final because of REGISTER_UPP 2024-03-08 19:43:26 -05:00
16fc4da41c null check i2pRouter in REGISTER_UPP 2024-03-08 19:36:29 -05:00
2c44a9c8ad get rid of setNotStarting 2024-03-08 19:19:36 -05:00
35666caefd Reign in some of the insanity 2024-03-08 19:04:56 -05:00
bf89c119a7 start getting rid of CCD 2024-03-08 18:44:24 -05:00
1277dae92b Delete unused functions from WinLauncher.java 2024-03-08 16:18:21 -05:00
a4476dc990 fix path for default plugin install 2024-03-08 15:06:30 -05:00
1e959d0aa1 fix path for default plugin install 2024-03-08 14:54:39 -05:00
8f6e7bc83c use i2p.plugins.firefox as a plugin instead of as a library 2024-03-08 11:58:49 -05:00
fc84098dc9 use i2p.plugins.firefox as a plugin instead of as a library 2024-03-07 22:31:18 -05:00
52a33b5334 zip during run phase 2024-03-07 22:18:41 -05:00
e055eb8aa9 don't skip unpacking 2024-03-07 21:21:01 -05:00
8d1eb7e01f remove shasums from ci artifact names 2024-03-07 20:57:38 -05:00
ab1d7047ca do releases builds with CI here too 2024-03-07 16:33:12 -05:00
9a190ae75d do releases builds with CI here too 2024-03-07 16:28:57 -05:00
38aa89e586 remove browser launcher from win launcher 2024-03-06 14:54:31 -05:00
9b10707f14 use powershell-zip if zip isn't around 2024-02-20 17:11:06 -05:00
79f3337056 don't run tbb script on Windows 2024-02-20 17:06:06 -05:00
7a550091f2 try chocowget for zip 2024-02-20 16:51:39 -05:00
4767e1fba2 make sure we're in wsl with zip 2024-02-20 16:37:39 -05:00
ef99328eed add zip to wsl env in buildzip 2024-02-20 16:04:06 -05:00
936966ee4c use choco to install wget 2024-02-20 15:13:55 -05:00
07aed0ab00 use choco to install wget 2024-02-20 14:52:22 -05:00
d70eb26dbf use wsl-bash to generate zip 2024-02-20 14:44:03 -05:00
df2802bf5d fix path for dev build artifact upload 2024-02-20 14:41:03 -05:00
4fdc0a5dc9 set up git config in container 2024-02-20 14:28:49 -05:00
e619b3fd19 pass -c 2024-02-20 14:18:37 -05:00
e1e61ec7b2 use winbash to run buildscripts 2024-02-20 14:06:06 -05:00
3d7444e33e use git-bash to run buildscripts 2024-02-20 11:38:31 -05:00
b75da98147 use wsl-bash to run buildscripts 2024-02-20 10:52:19 -05:00
3d70bc5e59 use git-bash to run buildscripts 2024-02-20 10:45:58 -05:00
ab7b24bb0d call wsl not wsl-bash when using apt-get 2024-02-20 10:39:44 -05:00
9baefba911 don't auto-select wsl-bash 2024-02-20 10:36:12 -05:00
f48d8017c5 add .gitattributes 2024-02-20 09:47:13 -05:00
d01d0bb513 force unix line endings 2024-02-19 19:09:46 -05:00
5e26057f9c force unix line endings 2024-02-19 19:02:43 -05:00
8be149e02f use checkout earlier 2024-02-19 18:46:19 -05:00
d73832f1f6 dos2unix everything in wsl 2024-02-19 18:12:36 -05:00
a7ae0ec8f7 dos2unix everything in wsl 2024-02-19 17:17:26 -05:00
6ec4834a08 work around error that happens in nsis 2024-02-19 17:04:46 -05:00
82d111d598 work around error that happens in nsis 2024-02-19 16:58:47 -05:00
2ed7e7ef98 work around error that happens in nsis 2024-02-19 16:48:59 -05:00
bdf8715ce5 fix syntax error on nsis target 2024-02-19 16:41:58 -05:00
175e811ac3 don't try and specify a shell 2024-02-19 16:37:14 -05:00
b3ff9d50f8 don't try and specify a shell 2024-02-19 16:35:11 -05:00
31135cc664 don't look for .tgz's pointlessly 2024-02-19 16:33:23 -05:00
5c91612f90 try and fix nsis target 2024-02-19 16:32:10 -05:00
c65df41f76 fix TBB download script for unix portable target 2024-02-19 16:27:51 -05:00
1a78538525 pass -y flag 2024-02-19 16:16:34 -05:00
8ec161aceb needs more gettext 2024-02-19 16:15:11 -05:00
c76541979a run apt-get update first 2024-02-19 16:08:46 -05:00
6f14dc1a3a use sudo in ubuntu container 2024-02-19 16:07:35 -05:00
7a32f97f29 install deps in ubuntu container also 2024-02-19 16:05:24 -05:00
790300e996 set default shell to wsl-bash 2024-02-19 16:03:04 -05:00
6a4aa0b74c Work on getting portable and nsis builds to work 2024-02-19 15:57:31 -05:00
32e26956bf Build all potential jpackage targets in CI 2024-02-19 15:42:45 -05:00
b8c1c44e66 Install Ubuntu-20.04 in wsl in CI so we can do the whole build process for all windows platforms 2024-02-19 15:32:52 -05:00
0a52d64847 switch back to what works for tonight 2024-02-01 22:05:23 -05:00
23e77ef901 list users, then fail to install Ubuntu as admin 2024-02-01 21:13:16 -05:00
3f419675fe set i2pversion not config.sh 2024-02-01 21:11:43 -05:00
99a779d89f set i2pversion not config.sh 2024-02-01 18:40:08 -05:00
2ce03a426c set i2pversion not config.sh 2024-02-01 17:54:47 -05:00
ab9965e0b8 don't worry about wsl for now 2024-02-01 17:31:22 -05:00
6491551577 diverges enough for the comment to be erroneous 2024-02-01 17:30:31 -05:00
ec13b0f94b try to fix artifact upload 2024-02-01 17:29:46 -05:00
11b7096fa5 try to fix config.sh in CI 2024-02-01 17:28:46 -05:00
1959aac3a8 try to fix config.sh in CI 2024-02-01 17:17:45 -05:00
1414fe3b53 try to fix config.sh in CI 2024-02-01 17:13:07 -05:00
03a3487aa7 try to fix config.sh in CI 2024-02-01 17:11:56 -05:00
bb55985bb8 try to fix config.sh in CI 2024-02-01 17:10:11 -05:00
95fbcde2dc try to fix config.sh in CI 2024-02-01 17:08:10 -05:00
157821ef91 install dos2unix in CI 2024-02-01 17:05:46 -05:00
371428e03c install nsis in CI 2024-02-01 17:04:58 -05:00
9e90df0181 fix config setup 2024-02-01 17:03:03 -05:00
893f1f9043 call build.sh in correct location 2024-02-01 17:00:43 -05:00
d76c1ff567 fix config setup 2024-02-01 16:58:13 -05:00
56be9ed3e0 fix config setup 2024-02-01 16:56:19 -05:00
e3e19ca4d4 see if jpackage can generate an exe 2024-02-01 16:54:52 -05:00
144e6ba9e0 call bash specifically 2024-02-01 16:36:35 -05:00
b2fdfc1e89 install wsl in runner 2024-02-01 16:34:42 -05:00
b1db589787 set up runner that definitely won't work yet 2024-02-01 16:23:09 -05:00
a3da3c2ace update version numbers 2.4.0 2023-12-11 13:54:41 -05:00
5e27d8588a update version numbers, don't have osname be static 2023-12-11 13:53:14 -05:00
2a185f5fe3 Detect mktorrent if it exists on Windows 2023-07-10 20:18:53 -04:00
f0f194242b add tag to last element in github upload script 2023-07-10 20:00:36 -04:00
b9c6b6db49 add i2p org to github upload script 2023-07-10 19:28:20 -04:00
c14077606b fix upload script 2023-07-10 19:21:49 -04:00
f53a7759e4 update versions 2023-07-10 15:16:06 -04:00
0566665a24 update version numbers 2023-07-10 15:03:20 -04:00
9d8da8b65a update version numbers 2023-07-10 15:02:54 -04:00
idk
cbf693dfb3 move more stuff out of makefiles and into scripts 2023-04-30 05:50:03 +00:00
idk
2b24239267 add torrent releaser script 2023-04-30 05:20:28 +00:00
idk
706ae974bc add download-back buildscript 2023-04-30 05:05:46 +00:00
idk
d7544ced5f Remove redundant clean 2023-04-28 20:36:36 +00:00
idk
ec44c0f6e3 remove redundant clean 2023-04-28 20:35:34 +00:00
idk
10fe05066c use powershell before which wget in wget finder function 2023-04-24 16:28:29 +00:00
idk
a5c7bac581 zip in release upload 2023-04-22 15:33:40 +00:00
idk
7eeb2e4523 add release uploader script 2023-04-22 06:14:05 +00:00
idk
9cae0f78ad add release uploader script 2023-04-22 06:06:11 +00:00
idk
99438cfc33 fix changelog date 2023-04-22 06:00:58 +00:00
idk
eba4ebe3d0 remove last few references to wsl 2023-04-22 05:50:24 +00:00
idk
7f24838725 ShellExecAsUser is not required for installers that do not run as admin, this installer is adminless 2023-04-19 03:30:06 +00:00
idk
673725304c ShellExecAsUser is not required for installers that do not run as admin, this installer is adminless 2023-04-19 02:13:43 +00:00
idk
7cf2bf455a fix licenses path on windows 2023-04-19 02:05:22 +00:00
idk
d177435b50 work around makensis path issues 2023-04-19 01:34:29 +00:00
idk
33fb6ab6d5 work around makensis path issues 2023-04-19 01:33:05 +00:00
idk
29827366fb work around makensis path issues 2023-04-19 01:30:01 +00:00
idk
edfe44bc3b work around makensis path issues 2023-04-19 01:26:11 +00:00
idk
432e2c54f8 bump version 2023-04-19 01:25:02 +00:00
idk
8894c946bc work around makensis path issues 2023-04-19 01:16:51 +00:00
idk
bc9b4a0250 use invoke-webrequest instead of wget on windows 2023-04-19 00:01:20 +00:00
idk
35841c7887 fix positional args for wsl-free build 2023-04-18 23:14:09 +00:00
idk
e3afb9de1d fix paths for wsl-free windows build 2023-04-18 23:03:48 +00:00
idk
3b11def66c fix paths for wsl-free windows build 2023-04-18 22:54:12 +00:00
idk
e152513043 Work around absence of wget, lessens requirement of wsl 2023-04-18 22:35:26 +00:00
idk
81dd3ed5ef update config file, automatically determine JAVA_HOME from java in path, automatically find apache ant 2023-04-18 20:28:41 +00:00
idk
0630f77a4c update .gitignore 2023-04-18 20:16:34 +00:00
idk
204fda1a11 Remove i2pbrowser-jpackage file 2023-04-18 20:14:33 +00:00
idk
9e1ef2d546 Remove i2pbrowser-jpackage file 2023-04-18 20:14:25 +00:00
idk
688bc1b0f3 update from 2.2.0 to 2.2.1 2023-04-18 20:10:10 +00:00
idk
dd566165dd update from -19 to -20 2023-04-18 20:07:41 +00:00
idk
57833edc36 always check out branch when building launcher, not just the first time 2023-03-20 17:27:16 +00:00
idk
a19fcd9ea5 remember to update I2PFIREFOX_VERSION to 1.0.9 2023-03-20 17:11:01 +00:00
idk
bfddc378cd update I2P version 2023-03-19 16:26:53 +00:00
idk
fd712293b4 update I2P version 2023-03-19 16:26:26 +00:00
idk
068fbee70e move extra docs to docs directory 2023-02-22 22:05:50 +00:00
idk
377c836887 fix other static reference conflicts 2023-02-12 19:27:24 +00:00
idk
99a4959c12 fix other static reference conflicts 2023-02-12 19:18:25 +00:00
idk
922ec66f95 only use instance reference to logger in static context 2023-02-12 19:05:56 +00:00
idk
298c87f457 update javadoc at top of winlauncher, lots more javadoc to do. 2023-02-12 16:52:40 +00:00
idk
fcacf59a48 main functions should still be static 2023-02-12 16:50:59 +00:00
idk
8d06c9079b main functions should still be static 2023-02-12 16:48:49 +00:00
idk
c0fb7dcf67 remove redundant admin check in nsis 2023-02-09 19:02:59 +00:00
idk
019581479b Tag nightlies with a date, remove jpackaged file from nsis installer 2023-02-09 02:48:49 +00:00
idk
65fb9e1847 Remove admin update subsystem along with admin installs. There is no more need to change the update URL on the first run now that it uses it's own directory. Tweak WindowsUpdatePostProcessor to use a zip update only as a backup. 2023-02-08 21:47:54 +00:00
idk
402cede106 mark Elevator and Shell32X for removal 2023-02-06 17:46:14 +00:00
idk
673d6b469f change appname 2023-01-31 20:10:19 +00:00
64 changed files with 3953 additions and 2241 deletions

1
.gitattributes vendored Normal file
View File

@ -0,0 +1 @@
* -text

135
.github/workflows/ant-latest.yml vendored Normal file
View File

@ -0,0 +1,135 @@
name: Java 22 CI
on:
push:
branches:
- main
- master
schedule:
- cron: '0 0 * * *' # Every day at midnight UTC
workflow_dispatch:
jobs:
nsis-jdk22:
runs-on: windows-latest
steps:
- uses: Vampire/setup-wsl@v3
with:
distribution: Ubuntu-20.04
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
git config --global user.email "github@i2p.net"
git config --global user.name "eyedeekay Github CI Build"
- uses: actions/checkout@v4
- run: wsl apt-get update
- run: wsl apt-get install -y nsis nsis-common nsis-pluginapi wget dos2unix curl jq gpg gettext
- name: Set up JDK 22
uses: actions/setup-java@v4
with:
java-version: '22'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/unsigned.sh; ls *.exe"
- name: Upload archived copy of I2P router source embedded in the build
uses: actions/upload-artifact@v4
with:
name: i2p.i2p.jpackage-build.tar.gz
path: i2p.i2p.jpackage-build.tar.gz
- name: Upload prebuilt jpackage bundle without any plugins or modded config
uses: actions/upload-artifact@v4
with:
name: I2P-Prebuilt.zip
path: I2P-Prebuilt.zip
- name: Upload I2P-Easy-Install-Bundle-unsigned.exe
uses: actions/upload-artifact@v4
with:
name: I2P-Easy-Install-Bundle-unsigned-jdk22.exe
path: I2P-Easy-Install-Bundle-*.exe
buildjpackagexe-jdk22:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 22
uses: actions/setup-java@v4
with:
java-version: '22'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/exe.sh; ls *.exe"
- name: Upload I2P-Easy-Install-Bundle-unsigned.exe
uses: actions/upload-artifact@v4
with:
name: I2P-EXE-unsigned-jdk22.exe
path: I2P-EXE-*.exe
buildjpackagmsi-jdk22:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 22
uses: actions/setup-java@v4
with:
java-version: '22'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/msi.sh; ls *.msi"
- name: Upload I2P-Easy-Install-Bundle-unsigned.msi
uses: actions/upload-artifact@v4
with:
name: I2P-MSI-unsigned-jdk22.msi
path: I2P-MSI-*.msi
buildzip-jdk22:
runs-on: windows-latest
steps:
- uses: Vampire/setup-wsl@v3
with:
distribution: Ubuntu-20.04
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
git config --global user.email "github@i2p.net"
git config --global user.name "eyedeekay Github CI Build"
- uses: actions/checkout@v4
- run: wsl apt-get update
- run: wsl apt-cache search 7zip
- run: wsl apt-get install -y nsis nsis-common nsis-pluginapi wget dos2unix curl jq gpg gettext zip p7zip-full ca-certificates
- run: choco install wget
- name: Set up JDK 22
uses: actions/setup-java@v4
with:
java-version: '22'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/zip.sh; ls -d * */* "
- name: Upload I2P-windows-portable.zip
uses: actions/upload-artifact@v4
with:
name: I2P-windows-portable-jdk22.zip
path: I2P-windows-portable.zip
buildtgz-jdk22:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 22
uses: actions/setup-java@v4
with:
java-version: '22'
distribution: 'temurin'
- run: |
sudo apt-get update
sudo apt-get install -y nsis nsis-common nsis-pluginapi wget dos2unix curl jq gpg gettext
- name: build with script
run: ./buildscripts/targz.sh; ls *.tar.gz
- name: Upload I2P.tar.gz
uses: actions/upload-artifact@v4
with:
name: I2P-jdk22.tar.gz
path: I2P.tar.gz

135
.github/workflows/ant.yml vendored Normal file
View File

@ -0,0 +1,135 @@
name: Java CI
on:
push:
branches:
- main
- master
schedule:
- cron: '0 0 * * *' # Every day at midnight UTC
workflow_dispatch:
jobs:
nsis:
runs-on: windows-latest
steps:
- uses: Vampire/setup-wsl@v3
with:
distribution: Ubuntu-20.04
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
git config --global user.email "github@i2p.net"
git config --global user.name "eyedeekay Github CI Build"
- uses: actions/checkout@v4
- run: wsl apt-get update
- run: wsl apt-get install -y nsis nsis-common nsis-pluginapi wget dos2unix curl jq gpg gettext
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/unsigned.sh; ls *.exe"
- name: Upload archived copy of I2P router source embedded in the build
uses: actions/upload-artifact@v4
with:
name: i2p.i2p.jpackage-build.tar.gz
path: i2p.i2p.jpackage-build.tar.gz
- name: Upload prebuilt jpackage bundle without any plugins or modded config
uses: actions/upload-artifact@v4
with:
name: I2P-Prebuilt.zip
path: I2P-Prebuilt.zip
- name: Upload I2P-Easy-Install-Bundle-unsigned.exe
uses: actions/upload-artifact@v4
with:
name: I2P-Easy-Install-Bundle-unsigned.exe
path: I2P-Easy-Install-Bundle-*.exe
buildjpackagexe:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/exe.sh; ls *.exe"
- name: Upload I2P-Easy-Install-Bundle-unsigned.exe
uses: actions/upload-artifact@v4
with:
name: I2P-EXE-unsigned.exe
path: I2P-EXE-*.exe
buildjpackagmsi:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/msi.sh; ls *.msi"
- name: Upload I2P-Easy-Install-Bundle-unsigned.msi
uses: actions/upload-artifact@v4
with:
name: I2P-MSI-unsigned.msi
path: I2P-MSI-*.msi
buildzip:
runs-on: windows-latest
steps:
- uses: Vampire/setup-wsl@v3
with:
distribution: Ubuntu-20.04
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
git config --global user.email "github@i2p.net"
git config --global user.name "eyedeekay Github CI Build"
- uses: actions/checkout@v4
- run: wsl apt-get update
- run: wsl apt-cache search 7zip
- run: wsl apt-get install -y nsis nsis-common nsis-pluginapi wget dos2unix curl jq gpg gettext zip p7zip-full ca-certificates
- run: choco install wget
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: build with script
run: bash -c "./buildscripts/zip.sh; ls -d * */* "
- name: Upload I2P-windows-portable.zip
uses: actions/upload-artifact@v4
with:
name: I2P-windows-portable.zip
path: I2P-windows-portable.zip
buildtgz:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- run: |
sudo apt-get update
sudo apt-get install -y nsis nsis-common nsis-pluginapi wget dos2unix curl jq gpg gettext
- name: build with script
run: ./buildscripts/targz.sh; ls *.tar.gz
- name: Upload I2P.tar.gz
uses: actions/upload-artifact@v4
with:
name: I2P.tar.gz
path: I2P.tar.gz

View File

@ -0,0 +1,101 @@
name: Nightly Release
on:
push:
branches:
- main
- master
schedule:
- cron: '0 0 * * *' # Every day at midnight UTC
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
sparse-checkout: |
changelog.txt
docs/RELEASE.md
sparse-checkout-cone-mode: false
- name: sleep 22 minutes
run: |
echo "sleeping 22 minutes to wait for artifacts"
sleep 1m
echo "sleeping 21 minutes to wait for artifacts"
sleep 1m
echo "sleeping 20 minutes to wait for artifacts"
sleep 1m
echo "sleeping 19 minutes to wait for artifacts"
sleep 1m
echo "sleeping 18 minutes to wait for artifacts"
sleep 1m
echo "sleeping 17 minutes to wait for artifacts"
sleep 1m
echo "sleeping 16 minutes to wait for artifacts"
sleep 1m
echo "sleeping 15 minutes to wait for artifacts"
sleep 1m
echo "sleeping 14 minutes to wait for artifacts"
sleep 1m
echo "sleeping 13 minutes to wait for artifacts"
sleep 1m
echo "sleeping 12 minutes to wait for artifacts"
sleep 1m
echo "sleeping 11 minutes to wait for artifacts"
sleep 1m
echo "sleeping 10 minutes to wait for artifacts"
sleep 1m
echo "sleeping 9 minutes to wait for artifacts"
sleep 1m
echo "sleeping 8 minutes to wait for artifacts"
sleep 1m
echo "sleeping 7 minutes to wait for artifacts"
sleep 1m
echo "sleeping 6 minutes to wait for artifacts"
sleep 1m
echo "sleeping 5 minutes to wait for artifacts"
sleep 1m
echo "sleeping 4 minutes to wait for artifacts"
sleep 1m
echo "sleeping 3 minutes to wait for artifacts"
sleep 1m
echo "sleeping 2 minutes to wait for artifacts"
sleep 1m
echo "sleeping 1 minutes to wait for artifacts"
sleep 1m
- name: Download artifacts
id: download-artifact
uses: dawidd6/action-download-artifact@v3
with:
skip_unpack: true
workflow: ant-latest.yml
if_no_artifact_found: fail
# remove .zip file extension
- run: for f in *.zip; do unzip "$f"; rm "$f"; done
- run: cp changelog.txt changelog-java22.txt
- run: echo "" | tee -a changelog-java22.txt
- run: echo "## Checksums" | tee -a changelog-java22.txt
- run: echo "" | tee -a changelog-java22.txt
- run: echo '```' | tee -a changelog-java22.txt
- run: sha256sum * | tee -a changelog-java22.txt
- run: echo '```' | tee -a changelog-java22.txt
- run: echo "" | tee -a changelog-java22.txt
- run: echo '```' | tee -a changelog-java22.txt
- run: file * | tee -a changelog-java22.txt
- run: echo '```' | tee -a changelog-java22.txt
- run: echo "" | tee -a changelog-java22.txt
- run: cat docs/RELEASE.md changelog-java22.txt > RELEASE.md
- name: Upload artifacts
uses: ncipollo/release-action@v1
with:
artifacts: "*"
prerelease: true
allowUpdates: true
replacesArtifacts: true
makeLatest: true
tag: nightly
bodyFile: "RELEASE.md"

96
.github/workflows/release-nightly.yml vendored Normal file
View File

@ -0,0 +1,96 @@
name: Nightly 22 Release
on:
push:
branches:
- main
- master
schedule:
- cron: '0 0 * * *' # Every day at midnight UTC
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
sparse-checkout: |
changelog.txt
docs/RELEASE.md
sparse-checkout-cone-mode: false
- name: sleep 15 minutes
run: |
echo "sleeping 20 minutes to wait for artifacts"
sleep 1m
echo "sleeping 19 minutes to wait for artifacts"
sleep 1m
echo "sleeping 18 minutes to wait for artifacts"
sleep 1m
echo "sleeping 17 minutes to wait for artifacts"
sleep 1m
echo "sleeping 16 minutes to wait for artifacts"
sleep 1m
echo "sleeping 15 minutes to wait for artifacts"
sleep 1m
echo "sleeping 14 minutes to wait for artifacts"
sleep 1m
echo "sleeping 13 minutes to wait for artifacts"
sleep 1m
echo "sleeping 12 minutes to wait for artifacts"
sleep 1m
echo "sleeping 11 minutes to wait for artifacts"
sleep 1m
echo "sleeping 10 minutes to wait for artifacts"
sleep 1m
echo "sleeping 9 minutes to wait for artifacts"
sleep 1m
echo "sleeping 8 minutes to wait for artifacts"
sleep 1m
echo "sleeping 7 minutes to wait for artifacts"
sleep 1m
echo "sleeping 6 minutes to wait for artifacts"
sleep 1m
echo "sleeping 5 minutes to wait for artifacts"
sleep 1m
echo "sleeping 4 minutes to wait for artifacts"
sleep 1m
echo "sleeping 3 minutes to wait for artifacts"
sleep 1m
echo "sleeping 2 minutes to wait for artifacts"
sleep 1m
echo "sleeping 1 minutes to wait for artifacts"
sleep 1m
- name: Download artifacts
id: download-artifact
uses: dawidd6/action-download-artifact@v3
with:
skip_unpack: true
workflow: ant.yml
if_no_artifact_found: fail
# remove .zip file extension
- run: for f in *.zip; do unzip "$f"; rm "$f"; done
- run: echo "" | tee -a changelog.txt
- run: echo "## Checksums" | tee -a changelog.txt
- run: echo "" | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: sha256sum * | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: echo "" | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: file * | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: echo "" | tee -a changelog.txt
- run: cat docs/RELEASE.md changelog.txt > RELEASE.md
- name: Upload artifacts
uses: ncipollo/release-action@v1
with:
artifacts: "*"
prerelease: true
allowUpdates: true
replacesArtifacts: true
makeLatest: true
tag: nightly
bodyFile: "RELEASE.md"

89
.github/workflows/release.yml vendored Normal file
View File

@ -0,0 +1,89 @@
name: Release
on:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'i2p-firefox-*.*.*' # Release i2p-firefox-1.2.3
- 'i2p-firefox-*.*.*-*' # Release i2p-firefox-1.2.3
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
with:
sparse-checkout: |
changelog.txt
docs/RELEASE.md
sparse-checkout-cone-mode: false
- name: sleep 15 minutes
run: |
echo "sleeping 20 minutes to wait for artifacts"
sleep 1m
echo "sleeping 19 minutes to wait for artifacts"
sleep 1m
echo "sleeping 18 minutes to wait for artifacts"
sleep 1m
echo "sleeping 17 minutes to wait for artifacts"
sleep 1m
echo "sleeping 16 minutes to wait for artifacts"
sleep 1m
echo "sleeping 15 minutes to wait for artifacts"
sleep 1m
echo "sleeping 14 minutes to wait for artifacts"
sleep 1m
echo "sleeping 13 minutes to wait for artifacts"
sleep 1m
echo "sleeping 12 minutes to wait for artifacts"
sleep 1m
echo "sleeping 11 minutes to wait for artifacts"
sleep 1m
echo "sleeping 10 minutes to wait for artifacts"
sleep 1m
echo "sleeping 9 minutes to wait for artifacts"
sleep 1m
echo "sleeping 8 minutes to wait for artifacts"
sleep 1m
echo "sleeping 7 minutes to wait for artifacts"
sleep 1m
echo "sleeping 6 minutes to wait for artifacts"
sleep 1m
echo "sleeping 5 minutes to wait for artifacts"
sleep 1m
echo "sleeping 4 minutes to wait for artifacts"
sleep 1m
echo "sleeping 3 minutes to wait for artifacts"
sleep 1m
echo "sleeping 2 minutes to wait for artifacts"
sleep 1m
echo "sleeping 1 minutes to wait for artifacts"
sleep 1m
- name: Download artifacts
id: download-artifact
uses: dawidd6/action-download-artifact@v3
with:
skip_unpack: true
workflow: ant.yml
if_no_artifact_found: fail
# remove .zip file extension
- run: for f in *.zip; do unzip "$f"; rm "$f"; done
- run: echo "" | tee -a changelog.txt
- run: echo "## Checksums" | tee -a changelog.txt
- run: echo "" | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: sha256sum * | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: echo "" | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: file * | tee -a changelog.txt
- run: echo '```' | tee -a changelog.txt
- run: echo "" | tee -a changelog.txt
- run: cat docs/RELEASE.md changelog.txt > RELEASE.md
- name: Upload artifacts
uses: ncipollo/release-action@v1
with:
artifacts: "*"
bodyFile: "RELEASE.md"

66
.github/workflows/sync.yaml vendored Normal file
View File

@ -0,0 +1,66 @@
# GitHub Actions workflow file to sync an external repository to this GitHub mirror.
# This file was automatically generated by go-github-sync.
#
# The workflow does the following:
# - Runs on a scheduled basis (and can also be triggered manually)
# - Clones the GitHub mirror repository
# - Fetches changes from the primary external repository
# - Applies those changes to the mirror repository
# - Pushes the updated content back to the GitHub mirror
#
# Authentication is handled by the GITHUB_TOKEN secret provided by GitHub Actions.
jobs:
sync:
runs-on: ubuntu-latest
steps:
- name: Validate Github Actions Environment
run: if [ "$GITHUB_ACTIONS" != "true" ]; then echo 'This script must be run in a GitHub Actions environment.'; exit 1; fi
- name: Checkout GitHub Mirror
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Configure Git
run: |-
git config user.name 'GitHub Actions'
git config user.email 'actions@github.com'
- env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
name: Sync Primary Repository
run: |-
# Add the primary repository as a remote
git remote add primary https://i2pgit.org/I2P_Developers/i2p.firefox.git
# Fetch the latest changes from the primary repository
git fetch primary
# Check if the primary branch exists in the primary repository
if git ls-remote --heads primary master | grep -q master; then
echo "Primary branch master found in primary repository"
else
echo "Error: Primary branch master not found in primary repository"
exit 1
fi
# Check if we're already on the mirror branch
if git rev-parse --verify --quiet master; then
git checkout master
else
# Create the mirror branch if it doesn't exist
git checkout -b master
fi
# Force-apply all changes from primary, overriding any conflicts
echo "Performing force sync from primary/master to master"
git reset --hard primary/master
# Push changes back to the mirror repository
git push origin master
name: Sync Primary Repository to GitHub Mirror
"on":
push: {}
schedule:
- cron: 0 * * * *
workflow_dispatch: {}

5
.gitignore vendored
View File

@ -25,4 +25,7 @@ config_override.sh
i2pkeys
onionkeys
tlskeys
tmp
tmp
/.stfolder/
/.vscode/
*github-release-config*.sh*

46
Dockerfile Normal file
View File

@ -0,0 +1,46 @@
FROM debian:sid
## Originally found at: https://yusuke.blog/2021/10/19/3149 and updated to Java 20.
## This does not work yet.
RUN dpkg --add-architecture i386
RUN apt-get update
RUN apt-get install -y curl fakeroot unzip gnupg dos2unix make nsis* dos2unix curl jq
# install JDK
RUN curl --output /opt/java20.zip https://download.java.net/java/GA/jdk20.0.1/b4887098932d415489976708ad6d1a4b/9/GPL/openjdk-20.0.1_windows-x64_bin.zip \
&& cd /opt/ \
&& unzip java20.zip \
&& rm java20.zip
ENV JAVA_HOME /opt/jdk-20.0.1
# install Wine
RUN apt-get update
RUN apt install --install-recommends wine wine64* wine-binfmt fonts-wine -y
RUN wine --version
RUN wine wineboot --init
# install WIX TOOLSET
RUN mkdir /opt/wix311 \
&& cd /opt/wix311 \
&& curl -L --output /opt/wix311/wix311.zip https://github.com/wixtoolset/wix3/releases/download/wix3112rtm/wix311-binaries.zip \
&& unzip wix311.zip \
&& rm wix311.zip
# WIX TOOLSET is requring .NET.
RUN curl --output winetricks https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks &&\
chmod +x winetricks && \
mv -v winetricks /usr/local/bin
# DONNO why dotnet48 installation fails with "warning: exit status 5 - user selected 'Cancel' "
# https://forum.winehq.org/viewtopic.php?f=8&t=35724
#ENV WINEPREFIX=/dotnet-test
#RUN /usr/local/bin/winetricks --optout -q dotnet48
ENV WINEPATH /opt/jdk-20.0.1/bin\;/opt/wix311
WORKDIR /root
COPY . /root
RUN echo "wine /opt/jdk-20.0.1/bin/jpackage.exe $@" > /opt/jdk-20.0.1/bin/jpackage
RUN chmod +x /opt/jdk-20.0.1/bin/jpackage
CMD ./buildscripts/build.sh

View File

@ -8,90 +8,113 @@
<meta name="keywords" content="master" />
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="showhider.css" />
<link rel="stylesheet" type="text/css" href="darklight.css" />
</head>
<body>
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="LICENSE.html">
LICENSE
</a>
</li>
<li>
<a href="UPDATES.html">
UPDATES
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
<input type="checkbox" id="checkboxDarkLight">
<div class="container">
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="LICENSE.html">
LICENSE
</a>
</li>
<li>
<a href="index.html">
index.html
</a>
</li>
<li>
<a href="docs/GOALS.html">
docs/GOALS
</a>
</li>
<li>
<a href="docs/PRINCIPLES.html">
docs/PRINCIPLES
</a>
</li>
<li>
<a href="docs/RELEASE.html">
docs/RELEASE
</a>
</li>
<li>
<a href="docs/UPDATES.html">
docs/UPDATES
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
</div>
</div>
</div>
</div>
<a id="returnhome" href="/">
/
</a>
<p>
Copyright 2018
</p>
<p>
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the &ldquo;Software&rdquo;), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
</p>
<p>
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
</p>
<p>
THE SOFTWARE IS PROVIDED &ldquo;AS IS&rdquo;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</p>
<div id="sourcecode">
<span id="sourcehead">
<strong>
Get the source code:
</strong>
</span>
<ul>
<li>
<a href="https://github.com/eyedeekay/i2p.firefox">
Source Repository: (https://github.com/eyedeekay/i2p.firefox)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
<a id="returnhome" href="/">
/
</a>
<div id="show">
<div id="hide">
<pre><code>Copyright 2018
<p>
Copyright 2018
</p>
<p>
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the &ldquo;Software&rdquo;), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
</p>
<p>
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
</p>
<p>
THE SOFTWARE IS PROVIDED &ldquo;AS IS&rdquo;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</p>
<div id="sourcecode">
<span id="sourcehead">
<strong>
Get the source code:
</strong>
</span>
<ul>
<li>
<a href="https://github.com/eyedeekay/i2p.firefox">
Source Repository: (https://github.com/eyedeekay/i2p.firefox)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
</a>
<div id="show">
<div id="hide">
<pre><code>Copyright 2018
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
@ -110,9 +133,10 @@ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</code></pre>
<a href="#hide">
Hide license
</a>
<a href="#hide">
Hide license
</a>
</div>
</div>
</div>
</div>
@ -121,7 +145,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</div>
<div>
<a href="https://geti2p.net/">
<img src="i2plogo.png"></img>
<img class="i2plogo" src="i2plogo.png"></img>
I2P
</a>
</div>

View File

@ -14,29 +14,19 @@ all: version install.exe
fmt:
find . -name '*.java' -exec clang-format -i {} \;
tag:
git tag $(PROFILE_VERSION)
version:
./buildscripts/version.sh
jpackage: version I2P build/I2P/config all
jpackage: version I2P build/I2P all
help: version
@echo "I2P-Easy-Install-Bundle-$(PROFILE_VERSION)"
@echo "$(SIGNER)"
@echo "$(I2P_VERSION)"
@echo "$(MAJOR).$(MINOR).$(BUILD)"
@echo "$(preset)"
prep:
install.exe:
./buildscripts/nsis.sh
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"
./buildscripts/unsigned.sh
distclean: clean
rm -rf I2P
@ -45,10 +35,9 @@ I2P:
./buildscripts/build.sh
build/I2P: I2P build
cp -v I2P build/I2P
src/I2P/config:
build/I2P/config: src/I2P/config build/I2P
build/I2P: build/I2P
#
# Warning: a displayed license file of more than 28752 bytes
@ -65,38 +54,3 @@ build:
@echo "creating build directory"
mkdir -p build
include makefiles/su.mk
include makefiles/su-unsigned.mk
I2P_DATE=`date +%Y-%m-%d`
MAGNET=`bttools torrent dumpinfo i2pwinupdate.su3.torrent | grep 'Magnet' | sed 's|Magnet: ||g' | sed 's|%3A|:|g'| sed 's|%2F|/|g'`
MAGNET_TESTING=`bttools torrent dumpinfo i2pwinupdate-testing.su3.torrent | grep 'MagNet' | sed 's|MagNet: ||g' | sed 's|%3A|:|g'| sed 's|%2F|/|g'`
magnet:
echo "$(MAGNET)"
BLANK=`awk '! NF { print NR; exit }' changelog.txt`
I2P.zip: I2P-jpackage-windows-$(I2P_VERSION).zip
I2P-jpackage-windows-$(I2P_VERSION).zip:
sh -c 'powershell Compress-Archive I2P I2P-jpackage-windows-$(I2P_VERSION).zip || zip I2P-jpackage-windows-$(I2P_VERSION).zip -r I2P'
changelog:
head -n "$(BLANK)" changelog.txt
release-jpackage: I2P-jpackage-windows-$(I2P_VERSION).zip
head -n "$(BLANK)" changelog.txt | gothub release -p -u eyedeekay -r i2p -t i2p-jpackage-windows-$(I2P_VERSION) -n i2p-jpackage-windows-$(I2P_VERSION) -d -; true
update-release-jpackage:
head -n "$(BLANK)" changelog.txt | gothub edit -p -u eyedeekay -r i2p -t i2p-jpackage-windows-$(I2P_VERSION) -n i2p-jpackage-windows-$(I2P_VERSION) -d -; true
delete-release-jpackage:
gothub delete -u eyedeekay -r i2p -t i2p-jpackage-windows-$(I2P_VERSION); true
upload-release-jpackage:
gothub upload -R -u eyedeekay -r i2p -t i2p-jpackage-windows-$(I2P_VERSION) -n "i2p-jpackage-windows-$(I2P_VERSION)" -f "./I2P-jpackage-windows-$(I2P_VERSION).zip"
jpackage-release: release-jpackage upload-release-jpackage

View File

@ -1,5 +1,5 @@
I2P Easy-Install Bundle for Windows(Also/formerly)I2P Browsing Profile for Firefox
==================================================================================
I2P Easy-Install Bundle for Windows, (Formerly)I2P Browsing Profile for Firefox
===============================================================================
Features:
---------
@ -13,6 +13,13 @@ Features:
Build Dependencies:
-------------------
**SHORTCUT:** All the build artifacts can be produced by the description in the `.yaml` files in `.github/workflows`.
These can be run on Github's infrastructure, or on a local(Windows) PC using https://github.com/nektos/act.
Doing things this way deals with all the dependency issues that Windows doesn't really give you a good way to deal with automatically.
It also guarantees that the same base container and environment gets used for every build no matter what machine it runs on.
I highly recommend you use either Github CI or `nektos/act` for dev builds of this software, as it **automates literally every one of the steps**.
CI-based builds follow the `WSL` version of the instructions.
To build this, you will need the following software packages
(all available in Debian and Ubuntu, see WSL section below):
@ -88,8 +95,8 @@ Windows Build
-------------
After installing the dependencies and completing the preparations,
just run `make`. This will produce the install.exe - the windows
installer, which sets up the shortcuts to launch Firefox on Windows.
just run `buildscripts/unsigned.sh`. This will produce the install.exe - the
windows installer, which sets up the shortcuts to launch Firefox on Windows.
Building without a jpackage is no longer supported.
When generating a build it's important to make sure that the
@ -130,7 +137,7 @@ Ubuntu in WSL.
7. Move into the i2p.firefox directory. Run the `./buildscripts/build.sh` script.
cd i2p.firefox
./buildscripts/build.sh
./buildscripts/unsigned.sh
8. Compile the NSIS installer using WSL.
@ -166,67 +173,18 @@ set up and you're using git bash, that is enough to make the scripts compatible
cd i2p.firefox
./buildscripts/unsigned.sh
6. Run `make` to build the installer.
Doing a Release
---------------
Once you have the installer `.exe` file produced by NSIS, you're almost ready to
do a release. As a final step, someone must sign the `.exe` file using a
Certificate which Windows will recognize. The current signer of the Windows
bundle is Zlatinb. Standard Windows signing tools are used.
Certificate which Windows will recognize. Standard Windows signing tools are used.
```sh
./release.sh
```
produces the binary.
Building a signed update file
-----------------------------
Building a signed update file for automatically updating a Windows I2P router
requires you to either be using linux, or have Go installed in your Cygwin or WSL environment.
On Linux(Where I sign the su3 files), this works:
make su3
to run the signing tool if necessary and then package the installer in a
signed update file.
Docker Support
--------------
**MOVED, DEPRECATION NOTICE:** Most of this functionality has been moved
to http://git.idk.i2p/idk/i2p.plugins.firefox which is more stable,
easier to build and use, and easier to incorporate into other
projects.
- https://git.idk.i2p/idk/i2p.plugins.firefox/-/blob/main/docker.sh
Unix Support
------------
**MOVED. DEPRECATION NOTICE:** Most of this functionality has been moved
to http://git.idk.i2p/idk/i2p.plugins.firefox which is more stable,
easier to build and use, and easier to incorporate into other
projects. It is the better option for nearly every non-Windows case
right now. You can get binary packages from:
- https://github.com/eyedeekay/i2p.plugins.firefox/releases
or look at
- https://i2pgit.org/idk/i2p.plugins.firefox/-/blob/master/PACKAGES.md
for instructions on how to build your own packages. These packages are
unofficial! Although I do dogfood most of them and the `.jar` gets thorough
testing.
**The only remotely interesting Unix functionality that remains in this**
**repository is the construction of a portable. You can use `targz.sh` to**
**generate that. Once generated, `cd I2P && ./lib/torbrowser.sh` to complete**
**setup, and `./bin/I2P` to run it.**
produces the binary and the su3.
Issues
------

View File

@ -1,166 +0,0 @@
<html>
<head>
<title>
I2P Easy-Install...
</title>
<meta name="author" content="eyedeekay" />
<meta name="description" content="i2p.firefox" />
<meta name="keywords" content="master" />
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="showhider.css" />
</head>
<body>
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="LICENSE.html">
LICENSE
</a>
</li>
<li>
<a href="UPDATES.html">
UPDATES
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
</div>
</div>
</div>
<a id="returnhome" href="/">
/
</a>
<h1>
Setting up an Update Server for an I2P Bundle
</h1>
<p>
It is important to set up a signed update server so that people are able to
safely and anonymously update your I2P bundle.
</p>
<h2>
The quick way:
</h2>
<p>
This process depends on my ability to push releases to github. If you are
forking, setting up a dev server, or taking over because I got hit by a bus,
you&rsquo;ll need to do it the complete way.
</p>
<p>
For as long as I am building updates, you will be able to mirror the jpackaged
Windows bundle by cloning the repository
<code>
https://github.com/eyedeekay/i2p
</code>
and
running the
<code>
make docker run
</code>
target in that repository. You can retrieve the
base32 address of your update server by viewing the log with
<code>
docker logs eephttpd-jpackage | grep b32.i2p | tee eephttpd-address.md
</code>
. To
update the site, run
<code>
./update.site.sh
</code>
in that repository.
</p>
<p>
Once you have cloned the repository and started the container with
<code>
make docker run
</code>
, you can simply add
<code>
path/to/repo/update-site.sh
</code>
to your
<code>
crontab
</code>
and it will update at an interval of your choosing.
</p>
<h2>
The complete way:
</h2>
<p>
TODO: describe how to do it with less of the awesome fancy stuff I put together
to make it easier on myself to keep an update server going.
</p>
<div id="sourcecode">
<span id="sourcehead">
<strong>
Get the source code:
</strong>
</span>
<ul>
<li>
<a href="https://github.com/eyedeekay/i2p.firefox">
Source Repository: (https://github.com/eyedeekay/i2p.firefox)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
</a>
<div id="show">
<div id="hide">
<pre><code>Copyright 2018
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</code></pre>
<a href="#hide">
Hide license
</a>
</div>
</div>
</div>
<div>
<iframe src="https://snowflake.torproject.org/embed.html" width="320" height="240" frameborder="0" scrolling="no"></iframe>
</div>
<div>
<a href="https://geti2p.net/">
<img src="i2plogo.png"></img>
I2P
</a>
</div>
</body>
</html>

View File

@ -1,29 +0,0 @@
Setting up an Update Server for an I2P Bundle
=============================================
It is important to set up a signed update server so that people are able to
safely and anonymously update your I2P bundle.
The quick way:
--------------
This process depends on my ability to push releases to github. If you are
forking, setting up a dev server, or taking over because I got hit by a bus,
you'll need to do it the complete way.
For as long as I am building updates, you will be able to mirror the jpackaged
Windows bundle by cloning the repository `https://github.com/eyedeekay/i2p` and
running the `make docker run` target in that repository. You can retrieve the
base32 address of your update server by viewing the log with
`docker logs eephttpd-jpackage | grep b32.i2p | tee eephttpd-address.md`. To
update the site, run `./update.site.sh` in that repository.
Once you have cloned the repository and started the container with
`make docker run`, you can simply add `path/to/repo/update-site.sh` to your
`crontab` and it will update at an interval of your choosing.
The complete way:
-----------------
TODO: describe how to do it with less of the awesome fancy stuff I put together
to make it easier on myself to keep an update server going.

View File

@ -55,7 +55,12 @@ echo "preparing to invoke jpackage for I2P version $I2P_VERSION"
rm -rf I2P
if [ ! -d "I2P" ]; then
"$JAVA_HOME"/bin/jpackage --type app-image --name I2P --app-version "$I2P_VERSION" \
if echo "$I2P_VERSION" | grep "master"; then
RELEASE_VERSION="9.9.9"
else
RELEASE_VERSION="$I2P_VERSION"
fi
"$JAVA_HOME"/bin/jpackage --type app-image --name I2P --app-version "$RELEASE_VERSION" \
--verbose \
--java-options "-Xmx512m" \
--java-options "--add-opens java.base/java.lang=ALL-UNNAMED" \
@ -80,4 +85,5 @@ cp "$SCRIPT_DIR/../i2p.i2p.jpackage-build/LICENSE.txt" license/I2P.txt
mkdir -p "$SCRIPT_DIR"/build/I2P
cp -rv "$SCRIPT_DIR"/I2P/* "$SCRIPT_DIR"/build/I2P
cp -rv src/I2P/config build/I2P/config
cp -rv src/I2P/config build/I2P/config
zip -r I2P-Prebuilt.zip build/I2P/

View File

@ -7,8 +7,13 @@ cd "$SCRIPT_DIR" || exit 1
. ./config.sh
. ./i2pversion
./build.sh
jpackage --name I2P-EXE --app-version "$I2P_VERSION" \
./buildscripts/build.sh
if echo "$I2P_VERSION" | grep "master"; then
RELEASE_VERSION="9.9.9"
else
RELEASE_VERSION="$I2P_VERSION"
fi
jpackage --name I2P-EXE --app-version "$RELEASE_VERSION" \
--verbose \
--java-options "-Xmx512m" \
--java-options "--add-opens java.base/java.lang=ALL-UNNAMED" \

View File

@ -30,10 +30,10 @@ if [ "$JAVA" -lt "17" ]; then
fi
if [ -z "${JAVA_HOME}" ]; then
export JAVA_HOME=`type -p java|xargs readlink -f|xargs dirname|xargs dirname`
export JAVA_HOME=$(type -p java|xargs readlink -f|xargs dirname|xargs dirname)
fi
if [ "$(expr substr $(uname -s) 1 5)" == "Linux" ]; then
export JAVA_HOME=`type -p java|xargs readlink -f|xargs dirname|xargs dirname`
export JAVA_HOME=$(type -p java|xargs readlink -f|xargs dirname|xargs dirname)
fi
echo "Building with: $JAVA, $JAVA_HOME"
sleep 5s
@ -48,18 +48,35 @@ export I2P_JARS="$I2P_PKG/lib"
export I2P_JBIGI="$SCRIPT_DIR/../i2p.i2p.jpackage-build/installer/lib/jbigi"
export I2P_JBIGI_JAR="$SCRIPT_DIR/../i2p.i2p.jpackage-build/build/jbigi.jar"
if [ ! -d "$SCRIPT_DIR/../i2p.i2p.jpackage-build/" ]; then
git clone --depth=1 -b "$VERSION" https://i2pgit.org/i2p-hackers/i2p.i2p "$SCRIPT_DIR/../i2p.i2p.jpackage-build/"
if [ -d "$SCRIPT_DIR/../i2p.i2p/" ]; then
echo cloning from local i2p.i2p checkout
git clone --depth=1 -b "$VERSION" -l "$SCRIPT_DIR/../i2p.i2p/" "$SCRIPT_DIR/../i2p.i2p.jpackage-build/"
else
echo cloning from remote i2p.i2p repository
git clone --depth=1 -b "$VERSION" https://i2pgit.org/I2P_Developers/i2p.i2p "$SCRIPT_DIR/../i2p.i2p.jpackage-build/"
fi
fi
cd "$SCRIPT_DIR/../i2p.i2p.jpackage-build/"
echo "setting up git branch for build"
OLDEXTRA=$(find . -name RouterVersion.java -exec grep 'String EXTRA' {} \;)
if [ -z "$EXTRA" ]; then
export EXTRACODE="win"
export EXTRA=" public final static String EXTRA = \"-$EXTRACODE\";"
fi
if [ "$VERSION" = master ]; then
VERSIONDATE="$(date +%m%d)"
else
export TAG_VERSION="$VERSION"
fi
echo "build is: i2p-$TAG_VERSION-$VERSIONDATE-$EXTRACODE"
find . -name RouterVersion.java -exec sed -i "s|$OLDEXTRA|$EXTRA|g" {} \;
git checkout -b "i2p-$VERSION-$EXTRACODE" && git commit -am "i2p-$VERSION-$EXTRACODE"
git switch - || :
git pull --tags
git archive --format=tar.gz --output="$SCRIPT_DIR/../i2p.firefox/i2p.i2p.jpackage-build.tar.gz" "i2p-$VERSION-$EXTRACODE"
git checkout -b "i2p-$TAG_VERSION-$VERSIONDATE-$EXTRACODE" || :
git commit -am "i2p-$TAG_VERSION-$VERSIONDATE-$EXTRACODE" || :
git archive --format=tar.gz --output="$SCRIPT_DIR/../i2p.firefox/i2p.i2p.jpackage-build.tar.gz" "i2p-$TAG_VERSION-$VERSIONDATE-$EXTRACODE"
git checkout "i2p-$TAG_VERSION-$VERSIONDATE-$EXTRACODE" || :
for i in $COUNT; do
echo -n "$i...."; sleep 1s
@ -70,7 +87,7 @@ ant jbigi
cd "$SCRIPT_DIR"
mkdir -p "$SCRIPT_DIR/src/I2P/config"
rm -rf "$SCRIPT_DIR/src/I2P/config/geoip" "$SCRIPT_DIR/src/I2P/config/webapps" "$SCRIPT_DIR/src/I2P/config/certificates"
rm -rf "$SCRIPT_DIR/src/I2P/config/geoip" "$SCRIPT_DIR/src/I2P/config/webapps" "$SCRIPT_DIR/src/I2P/config/certificates" "$SCRIPT_DIR/src/I2P/config/eepsite"
cp -v "$RES_DIR/clients.config" "$SCRIPT_DIR/src/I2P/config/"
cp -v "$RES_DIR/wrapper.config" "$SCRIPT_DIR/src/I2P/config/"
#grep -v 'router.updateURL' $(RES_DIR)/router.config > "$SCRIPT_DIR"/src/I2P/config/router.config
@ -89,15 +106,25 @@ mkdir -p "$SCRIPT_DIR/build"
cp "$I2P_JARS"/*.jar "$SCRIPT_DIR/build"
cp "$I2P_JBIGI_JAR" "$SCRIPT_DIR/build"
if [ ! -f "$SCRIPT_DIR/build/jna.jar" ]; then
wget -O "$SCRIPT_DIR/build/jna.jar" "https://repo1.maven.org/maven2/net/java/dev/jna/jna/$JNA_VERSION/jna-$JNA_VERSION.jar"
echo "downloading jna"
wget_download "https://repo1.maven.org/maven2/net/java/dev/jna/jna/$JNA_VERSION/jna-$JNA_VERSION.jar" -O "$SCRIPT_DIR/build/jna.jar"
fi
if [ ! -f "$SCRIPT_DIR/build/jna-platform.jar" ]; then
wget -O "$SCRIPT_DIR/build/jna-platform.jar" "https://repo1.maven.org/maven2/net/java/dev/jna/jna-platform/$JNA_VERSION/jna-platform-$JNA_VERSION.jar"
echo "downloading jna-platform"
wget_download "https://repo1.maven.org/maven2/net/java/dev/jna/jna-platform/$JNA_VERSION/jna-platform-$JNA_VERSION.jar" -O "$SCRIPT_DIR/build/jna-platform.jar"
fi
if [ ! -f "$SCRIPT_DIR/build/i2pfirefox.jar" ]; then
wget -O "$SCRIPT_DIR/build/i2pfirefox.jar" "https://github.com/eyedeekay/i2p.plugins.firefox/releases/download/$I2PFIREFOX_VERSION/i2pfirefox.jar"
if [ ! -f "$SCRIPT_DIR/build/i2pfirefox.zip" ]; then
echo "downloading i2pfirefox jars"
wget_download "https://github.com/eyedeekay/i2p.plugins.firefox/releases/download/$I2PFIREFOX_VERSION/plugin.zip" -O "$SCRIPT_DIR/build/i2pfirefox.zip"
fi
if [ ! -d "$SCRIPT_DIR/src/I2P/config/plugins/i2pfirefox" ]; then
mkdir -p "$SCRIPT_DIR/src/I2P/config/plugins/"
unzip "$SCRIPT_DIR/build/i2pfirefox.zip" -d "$SCRIPT_DIR/src/I2P/config/plugins/"
rm -rf "$SCRIPT_DIR/src/I2P/config/plugins/i2pfirefox"
mv "$SCRIPT_DIR/src/I2P/config/plugins/plugin" "$SCRIPT_DIR/src/I2P/config/plugins/i2pfirefox"
fi
for dll in "$I2P_JBIGI/"*windows*.dll; do
@ -105,15 +132,13 @@ for dll in "$I2P_JBIGI/"*windows*.dll; do
done
cd "$SCRIPT_DIR"/java
"$JAVA_HOME"/bin/javac -d ../build -classpath "$SCRIPT_DIR/build/i2pfirefox.jar:$SCRIPT_DIR/build/jna.jar":"$SCRIPT_DIR/build/jna-platform.jar":"$SCRIPT_DIR/build/i2p.jar":"$SCRIPT_DIR/build/router.jar":"$SCRIPT_DIR/build/routerconsole.jar":"$SCRIPT_DIR/build/jbigi.jar" \
net/i2p/router/CopyConfigDir.java \
net/i2p/router/Elevator.java \
net/i2p/router/Shell32X.java \
"$JAVA_HOME"/bin/javac -Xlint:deprecation -d ../build -classpath "$SCRIPT_DIR/build/i2pfirefox.jar:$SCRIPT_DIR/build/jna.jar:$SCRIPT_DIR/build/jna-platform.jar":"$SCRIPT_DIR/build/i2p.jar:$SCRIPT_DIR/build/router.jar:$SCRIPT_DIR/build/routerconsole.jar:$SCRIPT_DIR/build/jbigi.jar" \
net/i2p/router/I2PAppUtil.java \
net/i2p/router/WindowsAppUtil.java \
net/i2p/router/WindowsServiceUtil.java \
net/i2p/router/WinLauncher.java \
net/i2p/router/WindowsUpdatePostProcessor.java \
net/i2p/router/WinUpdatePostProcessor.java \
net/i2p/router/WinUpdateProcess.java \
net/i2p/router/WindowsServiceUtil.java \
net/i2p/router/ZipUpdateProcess.java
cd ..

View File

@ -9,7 +9,12 @@ cd "$SCRIPT_DIR" || exit 1
. ./i2pversion
"$SCRIPT_DIR"/buildscripts/build.sh
jpackage --name I2P-MSI --app-version "$I2P_VERSION" \
if echo "$I2P_VERSION" | grep "master"; then
RELEASE_VERSION="9.9.9"
else
RELEASE_VERSION="$I2P_VERSION"
fi
jpackage --name I2P-MSI --app-version "$RELEASE_VERSION" \
--verbose \
--java-options "-Xmx512m" \
--java-options "--add-opens java.base/java.lang=ALL-UNNAMED" \

67
buildscripts/news.sh Executable file
View File

@ -0,0 +1,67 @@
#! /usr/bin/env bash
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1
. "$SCRIPT_DIR/i2pversion"
if [ -f i2pversion_override ]; then
. "$SCRIPT_DIR/i2pversion_override"
fi
. "$SCRIPT_DIR/config.sh"
if [ -f "$SCRIPT_DIR/config_override.sh" ]; then
. "$SCRIPT_DIR/config_override.sh"
fi
if [ -z "$I2P_NEWSXML" ]; then
if [ -d "../i2p.newsxml" ]; then
export I2P_NEWSXML="../i2p.newsxml"
else
echo "i2p.newsxml is not in the parent directory and I2P_NEWSXML is unset"
exit 1
fi
fi
cd "$I2P_NEWSXML" || exit 1
export TITLE="Easy-Install for Windows Release $I2P_VERSION"
echo "$TITLE"
export AUTHOR=idk
echo "$AUTHOR"
export EDITOR=true
echo "canceled manual editor"
export I2P_OS=win
echo "$I2P_OS"
export I2P_BRANCH=beta
echo "$I2P_VERSION"
export SUMMARY_HERE=$(head -n 1 "$SCRIPT_DIR/docs/RELEASE.md" | sed "s|# ||g")
echo "$SUMMARY_HERE"
export CONTENT_HERE=$(tail -n +2 "$SCRIPT_DIR/docs/RELEASE.md" | markdown)
echo "$CONTENT_HERE" > news-content.html
unset CONTENT_HERE
./create_new_entry.sh
export DATE=$(date +%Y-%m-%d)
echo "$DATE"
MAGNET=$(transmission-show -m "$SCRIPT_DIR/i2pwinupdate.su3.torrent" 2>&1 3>&1 | tail -n 1)
TORRENTJSON='['
TORRENTJSON+=' {'
TORRENTJSON+=" \"date\": \"$DATE\","
TORRENTJSON+=" \"version\": \"$I2P_VERSION\","
TORRENTJSON+=" \"minVersion\": \"1.5.0\","
TORRENTJSON+=" \"minJavaVersion\": \"1.8\","
TORRENTJSON+=" \"updates\": {"
TORRENTJSON+=" \"su3\": {"
TORRENTJSON+=" \"torrent\": \"$MAGNET\","
TORRENTJSON+=" \"url\": ["
TORRENTJSON+=" \"http://ekm3fu6fr5pxudhwjmdiea5dovc3jdi66hjgop4c7z7dfaw7spca.b32.i2p/i2pwinupdate.su3\""
TORRENTJSON+=' ]'
TORRENTJSON+=' }'
TORRENTJSON+=' }'
TORRENTJSON+=' }'
TORRENTJSON+=']'
echo "$TORRENTJSON" | jq > "$I2P_NEWSXML/data/win/beta/releases.json"
echo "$TORRENTJSON" | jq > "$I2P_NEWSXML/data/win/testing/releases.json"

View File

@ -15,12 +15,7 @@ if [ -f "$SCRIPT_DIR/config_override.sh" ]; then
. "$SCRIPT_DIR/config_override.sh"
fi
MAKENSIS=$(which makensis)
if [ -z "$MAKENSIS" ]; then
MAKENSIS="wsl makensis"
fi
cp "$SCRIPT_DIR"/src/nsis/*.nsi "$SCRIPT_DIR"/build
cp "$SCRIPT_DIR"/src/nsis/*.nsh "$SCRIPT_DIR"/build
cp "$SCRIPT_DIR"/src/icons/*.ico "$SCRIPT_DIR"/build
cd "$SCRIPT_DIR"/build && $MAKENSIS i2pbrowser-installer.nsi && cp I2P-Easy-Install-Bundle-*.exe ../ && echo "built windows installer"
cd "$SCRIPT_DIR"/build && makensisi i2pbrowser-installer.nsi && cp I2P-Easy-Install-Bundle-*.exe ../ && echo "built windows installer"

View File

@ -0,0 +1,42 @@
#! /usr/bin/env bash
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1
. "$SCRIPT_DIR/i2pversion"
if [ -f i2pversion_override ]; then
. "$SCRIPT_DIR/i2pversion_override"
fi
mv "$SCRIPT_DIR/config_override.sh" "$SCRIPT_DIR/config_override.sh.bak"
. "$SCRIPT_DIR/config.sh"
### How to set up this script:
#
# This script will not work unless you give it a Github API key.
# You need to create a file in your $HOME directory, which on
# Windows will by /c/Users/yourusername, called github-release-config.sh,
# containing this key as the variable GITHUB_TOKEN.
# github-release-config.sh must also contain:
# GITHUB_USERNAME=your github username
. "$HOME/github-release-config.sh"
if [ -f ./i2pversion_override ]; then
. ./i2pversion_override
fi
echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -t "i2p-firefox-$I2P_VERSION"
github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -t "i2p-firefox-$I2P_VERSION"
echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P-windows-portable.zip" -t "$I2P_VERSION"
github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "I2P-windows-portable.zip" -t "i2p-firefox-$I2P_VERSION"
echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p.i2p.jpackage-build.tar.gz" -t "i2p-firefox-$I2P_VERSION"
github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p.i2p.jpackage-build.tar.gz" -t "i2p-firefox-$I2P_VERSION"
echo github-release download -u "$GITHUB_USERNAME" -r i2p.firefox -t "i2p-firefox-$I2P_VERSION" -n "./I2P-jpackage-windows-$I2P_VERSION.zip"
github-release download -u "$GITHUB_USERNAME" -r i2p.firefox -t "i2p-firefox-$I2P_VERSION" -n "./I2P-jpackage-windows-$I2P_VERSION.zip"

50
buildscripts/release-support.sh Executable file
View File

@ -0,0 +1,50 @@
#! /usr/bin/env bash
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1
. "$SCRIPT_DIR/i2pversion"
if [ -f i2pversion_override ]; then
. "$SCRIPT_DIR/i2pversion_override"
fi
mv "$SCRIPT_DIR/config_override.sh" "$SCRIPT_DIR/config_override.sh.bak"
. "$SCRIPT_DIR/config.sh"
### How to set up this script:
#
# This script will not work unless you give it a Github API key.
# You need to create a file in your $HOME directory, which on
# Windows will by /c/Users/yourusername, called github-release-config.sh,
# containing this key as the variable GITHUB_TOKEN.
# github-release-config.sh must also contain:
# GITHUB_USERNAME=your github username
. "$HOME/github-release-config.sh"
if [ -f ./i2pversion_override ]; then
. ./i2pversion_override
fi
echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2pwinupdate.su3" -t "$I2P_VERSION"
github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2pwinupdate.su3" -t "$I2P_VERSION"
echo github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2pwinupdate.su3.torrent" -t "$I2P_VERSION"
github-release download -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2pwinupdate.su3.torrent" -t "$I2P_VERSION"
if [ ! -z "$I2P_SNARK_DIR" ]; then
if [ "$I2P_SNARK_DIR" = "$HOME/.i2p/i2psnark" ]; then
cp -v "i2pwinupdate.su3" "$I2P_SNARK_DIR"
cp -v "i2pwinupdate.su3.torrent" "$I2P_SNARK_DIR"
fi
if [ "$I2P_SNARK_DIR" = "$LOCALAPPDATA/i2p/i2psnark/" ]; then
cp -v "i2pwinupdate.su3" "$I2P_SNARK_DIR"
cp -v "i2pwinupdate.su3.torrent" "$I2P_SNARK_DIR"
fi
if [ "$I2P_SNARK_DIR" = "/var/lib/i2p/i2p-config/i2psnark/" ]; then
sudo cp -v "i2pwinupdate.su3" "$I2P_SNARK_DIR"
sudo cp -v "i2pwinupdate.su3.torrent" "$I2P_SNARK_DIR"
sudo chown i2psvc:i2psvc "$I2P_SNARK_DIR/i2pwinupdate.su3" "$I2P_SNARK_DIR/i2pwinupdate.su3.torrent"
fi
fi

48
buildscripts/release-torrent.sh Executable file
View File

@ -0,0 +1,48 @@
#! /usr/bin/env bash
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1
. "$SCRIPT_DIR/i2pversion"
if [ -f i2pversion_override ]; then
. "$SCRIPT_DIR/i2pversion_override"
fi
mv "$SCRIPT_DIR/config_override.sh" "$SCRIPT_DIR/config_override.sh.bak"
. "$SCRIPT_DIR/config.sh"
### How to set up this script:
#
# This script will not work unless you give it a Github API key.
# You need to create a file in your $HOME directory, which on
# Windows will by /c/Users/yourusername, called github-release-config.sh,
# containing this key as the variable GITHUB_TOKEN.
# github-release-config.sh must also contain:
# GITHUB_USERNAME=your github username
. "$HOME/github-release-config.sh"
if [ -f ./i2pversion_override ]; then
. ./i2pversion_override
fi
if [ ! -f "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" ]; then
wget -c "https://github.com/eyedeekay/i2p.firefox/releases/download/i2p-firefox-$I2P_VERSION/I2P-Easy-Install-Bundle-$I2P_VERSION.exe"
fi
cp -v "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" "I2P-Easy-Install-Bundle-$I2P_VERSION-signed.exe"
java -cp "$I2P_LIBS/*" net.i2p.crypto.SU3File sign -c ROUTER -f EXE I2P-Easy-Install-Bundle-$I2P_VERSION-signed.exe I2P-Easy-Install-Bundle-$I2P_VERSION-signed.su3 "$HOME/.i2p-plugin-keys/news-su3-keystore.ks" $I2P_VERSION $SIGNER
rm -f i2pwinupdate.su3.torrent
cp -v I2P-Easy-Install-Bundle-$I2P_VERSION-signed.su3 i2pwinupdate.su3
java -cp "$I2P_LIBS/*" "org.klomp.snark.Storage" -a http://tracker2.postman.i2p/announce.php -c "$SIGNER" -m "Official torrent for Windows Easy-Install version $I2P_VERSION" i2pwinupdate.su3
echo "~~~~~~~~~~"
MAGNET=$(transmission-show -m "i2pwinupdate.su3.torrent" 2>&1 3>&1 | tail -n 1)
echo "$MAGNET"
ZIPCHECKSUM=$(sha256sum "i2pwinupdate.su3")
echo github-release upload -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "i2pwinupdate.su3" -l "$ZIPCHECKSUM" -t "i2p-firefox-$I2P_VERSION" -n "i2pwinupdate.su3"
github-release upload -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "i2pwinupdate.su3" -l "$ZIPCHECKSUM" -t "i2p-firefox-$I2P_VERSION" -n "i2pwinupdate.su3"
ZIPCHECKSUM=$(sha256sum "i2pwinupdate.su3.torrent")
echo github-release upload -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "i2pwinupdate.su3.torrent" -l "$ZIPCHECKSUM" -t "i2p-firefox-$I2P_VERSION" -n "i2pwinupdate.su3.torrent"
github-release upload -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "i2pwinupdate.su3.torrent" -l "$ZIPCHECKSUM" -t "i2p-firefox-$I2P_VERSION" -n "i2pwinupdate.su3.torrent"

73
buildscripts/release-upload.sh Executable file
View File

@ -0,0 +1,73 @@
#! /usr/bin/env bash
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1
. "$SCRIPT_DIR/i2pversion"
if [ -f i2pversion_override ]; then
. "$SCRIPT_DIR/i2pversion_override"
fi
mv "$SCRIPT_DIR/config_override.sh" "$SCRIPT_DIR/config_override.sh.bak"
. "$SCRIPT_DIR/config.sh"
### How to set up this script:
#
# This script will not work unless you give it a Github API key.
# You need to create a file in your $HOME directory, which on
# Windows will by /c/Users/yourusername, called github-release-config.sh,
# containing this key as the variable GITHUB_TOKEN.
# github-release-config.sh must also contain:
# GITHUB_USERNAME=your github username
git clean -fd
git checkout .
"$SCRIPT_DIR"/buildscripts/unsigned.sh
. "$HOME/github-release-config.sh"
if [ -f ./i2pversion_override ]; then
. ./i2pversion_override
fi
BLANK=$(awk '! NF { print NR; exit }' changelog.txt)
DESCRIPTION="Release build of i2p.firefox for $I2P_VERSION
==========================================================
$(head -n $BLANK changelog.txt)"
echo github-release release -p -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "$I2P_VERSION" -d "$DESCRIPTION" -t "$I2P_VERSION"
github-release release -p -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "$I2P_VERSION" -d "$DESCRIPTION" -t "$I2P_VERSION"
sleep 2s;
EXECHECKSUM=$(sha256sum "I2P-Easy-Install-Bundle-$I2P_VERSION.exe")
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -l "$EXECHECKSUM" -t "$I2P_VERSION" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -l "$EXECHECKSUM" -t "$I2P_VERSION" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe"
powershell Compress-Archive -force I2P I2P.zip
ZIPCHECKSUM=$(sha256sum "I2P.zip")
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P.zip" -l "$ZIPCHECKSUM" -t "$I2P_VERSION" -n "I2P.zip"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P.zip" -l "$ZIPCHECKSUM" -t "$I2P_VERSION" -n "I2P.zip"
TARCHECKSUM=$(sha256sum "../i2p.i2p.jpackage-build.tar.gz")
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "../i2p.i2p.jpackage-build.tar.gz" -l "Upstream I2P Router source code $TARCHECKSUM" -t "$I2P_VERSION" -n "i2p.i2p.jpackage-build.tar.gz"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "../i2p.i2p.jpackage-build.tar.gz" -l "Upstream I2P Router source code $TARCHECKSUM" -t "$I2P_VERSION" -n "i2p.i2p.jpackage-build.tar.gz"
sh -c "powershell Compress-Archive I2P I2P-jpackage-windows-$I2P_VERSION.zip || zip I2P-jpackage-windows-$I2P_VERSION.zip -r I2P"
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p-jpackage-windows-$I2P_VERSION.zip" -t "$I2P_VERSION" -f "./I2P-jpackage-windows-$I2P_VERSION.zip"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p-jpackage-windows-$I2P_VERSION.zip" -t "$I2P_VERSION" -f "./I2P-jpackage-windows-$I2P_VERSION.zip"
GITHUB_USERNAME=i2p
echo github-release release -p -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "$I2P_VERSION" -d "$DESCRIPTION" -t "$I2P_VERSION"
github-release release -p -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "$I2P_VERSION" -d "$DESCRIPTION" -t "$I2P_VERSION"
sleep 2s;
EXECHECKSUM=$(sha256sum "I2P-Easy-Install-Bundle-$I2P_VERSION.exe")
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -l "$EXECHECKSUM" -t "$I2P_VERSION" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P-Easy-Install-Bundle-$I2P_VERSION.exe" -l "$EXECHECKSUM" -t "$I2P_VERSION" -n "I2P-Easy-Install-Bundle-$I2P_VERSION.exe"
powershell Compress-Archive -force I2P I2P.zip
ZIPCHECKSUM=$(sha256sum "I2P.zip")
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P.zip" -l "$ZIPCHECKSUM" -t "$I2P_VERSION" -n "I2P.zip"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "I2P.zip" -l "$ZIPCHECKSUM" -t "$I2P_VERSION" -n "I2P.zip"
TARCHECKSUM=$(sha256sum "../i2p.i2p.jpackage-build.tar.gz")
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "../i2p.i2p.jpackage-build.tar.gz" -l "Upstream I2P Router source code $TARCHECKSUM" -t "$I2P_VERSION" -n "i2p.i2p.jpackage-build.tar.gz"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -f "../i2p.i2p.jpackage-build.tar.gz" -l "Upstream I2P Router source code $TARCHECKSUM" -t "$I2P_VERSION" -n "i2p.i2p.jpackage-build.tar.gz"
sh -c "powershell Compress-Archive I2P I2P-jpackage-windows-$I2P_VERSION.zip || zip I2P-jpackage-windows-$I2P_VERSION.zip -r I2P"
echo github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p-jpackage-windows-$I2P_VERSION.zip" -t "$I2P_VERSION" -f "./I2P-jpackage-windows-$I2P_VERSION.zip"
github-release upload -R -u "$GITHUB_USERNAME" -r "i2p.firefox" -n "i2p-jpackage-windows-$I2P_VERSION.zip" -t "$I2P_VERSION" -f "./I2P-jpackage-windows-$I2P_VERSION.zip"

View File

@ -10,7 +10,6 @@ if [ -f "$SCRIPT_DIR/config_override.sh" ]; then
fi
export machine=unix
"$SCRIPT_DIR"/buildscripts/clean.sh
wsl "$SCRIPT_DIR"/buildscripts/clean.sh
"$SCRIPT_DIR"/buildscripts/build.sh
cd "$SCRIPT_DIR/I2P" || exit 1

View File

@ -1,7 +1,7 @@
#! /usr/bin/env bash
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1
cd "$SCRIPT_DIR" || cd ../ ; SCRIPT_DIR=$(pwd)
. "$SCRIPT_DIR/config.sh"
@ -10,6 +10,5 @@ if [ -f "$SCRIPT_DIR/config_override.sh" ]; then
fi
"$SCRIPT_DIR"/buildscripts/clean.sh
wsl "$SCRIPT_DIR"/buildscripts/clean.sh
"$SCRIPT_DIR"/buildscripts/build.sh
"$SCRIPT_DIR"/buildscripts/nsis.sh

View File

@ -18,9 +18,9 @@ fi
echo "!define VERSIONMAJOR $VERSIONMAJOR" > "$SCRIPT_DIR"/src/nsis/i2pbrowser-version.nsi
echo "!define VERSIONMINOR $VERSIONMINOR" >> "$SCRIPT_DIR"/src/nsis/i2pbrowser-version.nsi
echo "!define VERSIONBUILD $VERSIONBUILD" >> "$SCRIPT_DIR"/src/nsis/i2pbrowser-version.nsi
echo "!define I2P_VERSION $PROFILE_VERSION" > "$SCRIPT_DIR"/src/nsis/i2pbrowser-jpackage.nsi
echo "!define I2P_VERSION $I2P_VERSION" > "$SCRIPT_DIR"/src/nsis/i2pbrowser-jpackage.nsi
mkdir -p "$SCRIPT_DIR"/build
echo "$PROFILE_VERSION" > "$SCRIPT_DIR"/build/version.txt
echo "$PROFILE_VERSION" > "$SCRIPT_DIR"/build/version.txt
echo "$I2P_VERSION" > "$SCRIPT_DIR"/build/version.txt
echo "$I2P_VERSION" > "$SCRIPT_DIR"/build/version.txt
sed 's|!define VERSION||g' "$SCRIPT_DIR"/src/nsis/i2pbrowser-version.nsi | sed 's| |=|g' > .version

View File

@ -0,0 +1,5 @@
#! /usr/bin/env sh
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1

View File

@ -1,7 +1,7 @@
#! /usr/bin/env bash
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd -P)/..
cd "$SCRIPT_DIR" || exit 1
cd "$SCRIPT_DIR" || cd ../ ; SCRIPT_DIR=$(pwd)
. "$SCRIPT_DIR/config.sh"
@ -9,7 +9,6 @@ if [ -f "$SCRIPT_DIR/config_override.sh" ]; then
. "$SCRIPT_DIR/config_override.sh"
fi
"$SCRIPT_DIR"/buildscripts/clean.sh
wsl "$SCRIPT_DIR"/buildscripts/clean.sh
"$SCRIPT_DIR"/buildscripts/build.sh
cd "$SCRIPT_DIR/I2P" || exit 1
@ -17,7 +16,8 @@ TORSOCKS=$(which torsocks)
if [ -f "${TORSOCKS}" ]; then
. "${TORSOCKS}" on
fi
"$SCRIPT_DIR"/src/win/torbrowser-windows.sh
which wsl && wsl ../src/win/torbrowser-windows.sh
which wsl || "$SCRIPT_DIR"/src/win/torbrowser-windows.sh
version="$(curl -s https://aus1.torproject.org/torbrowser/update_3/release/downloads.json | jq -r ".version")"
. "${TORSOCKS}" off
locale="en-US" # mention your locale. default = en-US
@ -29,5 +29,6 @@ rm -vrf "tor-browser_${locale}"
cd "$SCRIPT_DIR" || exit 1
rm -rf I2P-portable && cp -r I2P I2P-portable
#powershell Compress-Archive -force I2P-portable I2P-windows-portable.zip
zip -r I2P-windows-portable.zip I2P-portable
which zip && zip -r I2P-windows-portable.zip I2P-portable
which zip || powershell Compress-Archive -force I2P-portable I2P-windows-portable.zip

View File

@ -1,4 +1,8 @@
2022-01-23 idk
2025-06-05 idk
* Remove Chromium support completely. Much smaller binary now.
* Version 2.9.0
2023-01-23 idk
* Move build scripts to their own directory and make them use correct paths when moved
* Add EXTRA to router when generating embedded router jars.
@ -147,3 +151,24 @@
* start a changelog
* add version to the profile, independent of installer version
- version 0.1 corresponds to IDK version 0.03b
## Checksums
```
621301bd5f0e0ef1879ed16f8a40d5da9444525755736411fe1e326192f90cb2 I2P-EXE-2.4.992.exe
decbdef9ef24f6b614027afb006dc7ee4b4817f48a25dbd6af440a6f2be5ecb3 I2P-Easy-Install-Bundle-2.4.992.exe
bf6f5d162885798072cd61c098bbe871571ac116aaed411b330bab247064e399 I2P-MSI-2.4.992.msi
0b9c68a6d97727140e56bc80c0096db9340ce12d5bdb7cc3252713a7bb0d33ca I2P-windows-portable.zip
18d68eeb61762f0b8cef3505802b5d4a2fa1327fa0fd8f2f41775328361be60b I2P.tar.gz
669d353ea064a6a660ef94e8d70728f011e81f98b0fbf298b4d124bbcec7ba83 changelog.txt
```
```
I2P-EXE-2.4.992.exe: PE32+ executable (GUI) x86-64, for MS Windows
I2P-Easy-Install-Bundle-2.4.992.exe: PE32 executable (GUI) Intel 80386, for MS Windows, Nullsoft Installer self-extracting archive
I2P-MSI-2.4.992.msi: Composite Document File V2 Document, Little Endian, Os: Windows, Version 6.2, MSI Installer, Code page: 1252, Title: Installation Database, Subject: I2P-MSI, Author: Unknown, Keywords: Installer, Comments: This installer database contains the logic and data required to install I2P-MSI., Template: x64;1033, Revision Number: {F44ACC17-351A-4424-A4F5-7F9E52BBE96E}, Create Time/Date: Wed Mar 20 02:46:40 2024, Last Saved Time/Date: Wed Mar 20 02:46:40 2024, Number of Pages: 200, Number of Words: 10, Name of Creating Application: Windows Installer XML Toolset (3.14.0.8606), Security: 2
I2P-windows-portable.zip: Zip archive data, at least v2.0 to extract, compression method=deflate
I2P.tar.gz: gzip compressed data, from Unix, original size modulo 2^32 766935040
changelog.txt: ASCII text
```

View File

@ -5,24 +5,69 @@
uname=$(uname)
#export PATH="$PATH:/c/Program Files/Java/jdk-17.0.3/bin/"
#export JAVA_HOME="/c/Program Files/Java/jdk-17.0.3"
# to use it for Oracle OpenJDK18
# Third-party builders should always override this in config_override.sh
if [ -z "$SIGNER" ]; then
SIGNER=hankhill19580@gmail.com
export SIGNER=hankhill19580@gmail.com
fi
if [ -z "$I2P_LIBS" ]; then
if [ -d "$HOME/i2p/lib/" ]; then
I2P_LIBS="$HOME/i2p/lib/"
fi
if [ -d "$LOCALAPPDATA/i2p/lib/" ]; then
I2P_LIBS="$LOCALAPPDATA/i2p/lib/"
fi
if [ -d "/usr/share/i2p/lib/" ]; then
I2P_LIBS="/usr/share/i2p/lib/"
fi
fi
if [ -z "$I2P_SNARK_DIR" ]; then
if [ -d "$HOME/.i2p/i2psnark" ]; then
I2P_SNARK_DIR="$HOME/.i2p/i2psnark"
fi
if [ -d "$LOCALAPPDATA/i2p/i2psnark/" ]; then
I2P_SNARK_DIR="$LOCALAPPDATA/i2p/i2psnark/"
fi
if [ -d "/var/lib/i2p/i2p-config/i2psnark/" ]; then
I2P_SNARK_DIR="/var/lib/i2p/i2p-config/i2psnark/"
fi
fi
NSIS_PATH="/c/Program Files (x86)/NSIS/Bin"
PATH="$NSIS_PATH:$PATH:$NSIS_PATH/"
export PATH="$NSIS_PATH:$PATH:$NSIS_PATH/"
wget_download(){
which powershell && powershell Invoke-WebRequest $@ && return
wget $@
}
makensisi(){
which makensis && makensis $@ && return
which wsl && wsl makensis $@ && return
}
make_make(){
which make && make $@ && return
which wsl && wsl make $@ && return
}
if [[ -n "$IS_WSL" || -n "$WSL_DISTRO_NAME" ]]; then
PATH="/c/Program Files/Java/jdk-19/bin/:$PATH:/c/Program Files/Java/jdk-19/bin/"
export PATH="/c/Program Files/Java/jdk-19/bin/:$PATH:/c/Program Files/Java/jdk-19/bin/"
JAVA_HOME="/c/Program Files/Java/jdk-19"
export JAVA_HOME="/c/Program Files/Java/jdk-19"
JAVA_HOME=$(java -XshowSettings:properties -version 2>&1 | findstr "java.home" | sed 's| java.home = ||g')
export JAVA_HOME="$JAVA_HOME"
PATH="$JAVA_HOME/bin/:$PATH:$JAVA_HOME/bin/"
export PATH="$JAVA_HOME/bin/:$PATH:$JAVA_HOME/bin/"
HOST=win32
export HOST=win32
fi
if [ "${uname}" != "Linux" ]; then
PATH="/c/Program Files/Java/jdk-19/bin/:$PATH:/c/Program Files/Java/jdk-19/bin/"
export PATH="/c/Program Files/Java/jdk-19/bin/:$PATH:/c/Program Files/Java/jdk-19/bin/"
JAVA_HOME="/c/Program Files/Java/jdk-19"
export JAVA_HOME="/c/Program Files/Java/jdk-19"
JAVA_HOME=$(java -XshowSettings:properties -version 2>&1 | findstr "java.home" | sed 's| java.home = ||g')
export JAVA_HOME="$JAVA_HOME"
PATH="$JAVA_HOME/bin/:$PATH:$JAVA_HOME/bin/"
export PATH="$JAVA_HOME/bin/:$PATH:$JAVA_HOME/bin/"
HOST=win32
export HOST=win32
fi
@ -32,10 +77,10 @@ fi
## This isn't a default install location, obviously, it's where I unzipped it.
## It won't work for you unless you kurtly tell Windows that your name is `user`
## every time you make an account, like I do.
#PATH="/c/Users/user/Downloads/openjdk-19_windows-x64_bin/jdk-19/bin/:$PATH:/c/Users/user/Downloads/openjdk-19_windows-x64_bin/jdk-19/bin/"
#export PATH="/c/Users/user/Downloads/openjdk-19_windows-x64_bin/jdk-19/bin/:$PATH:/c/Users/user/Downloads/openjdk-19_windows-x64_bin/jdk-19/bin/"
#JAVA_HOME=/c/Users/user/Downloads/openjdk-19_windows-x64_bin/jdk-19
#export JAVA_HOME=/c/Users/user/Downloads/openjdk-19_windows-x64_bin/jdk-19
#PATH="/c/Users/user/Downloads/openjdk-20_windows-x64_bin/jdk-20/bin/:$PATH:/c/Users/user/Downloads/openjdk-20_windows-x64_bin/jdk-20/bin/"
#export PATH="/c/Users/user/Downloads/openjdk-20_windows-x64_bin/jdk-20/bin/:$PATH:/c/Users/user/Downloads/openjdk-20_windows-x64_bin/jdk-20/bin/"
#JAVA_HOME=/c/Users/user/Downloads/openjdk-20_windows-x64_bin/jdk-20
#export JAVA_HOME=/c/Users/user/Downloads/openjdk-20_windows-x64_bin/jdk-20
## Other potential values(NOT exhaustive):
@ -72,8 +117,17 @@ fi
# You can also use this to temporarily add applications into the PATH that are
# required to build this if you do not wish to edit your PATH across the entire
# Windows session, and for setting ANT_HOME
#export ANT_HOME="/c/apache-ant-1.10.9"
#export PATH="$PATH:$ANT_HOME/bin/"
if [ -d "/c/apache-ant-"* ]; then
ANT_HOME=$(ls -d /c/apache-ant-*)
export ANT_HOME="$ANT_HOME"
export PATH="$PATH:$ANT_HOME/bin/"
fi
if [ -d "/c/mktorrent"* ]; then
MKTORRENT_HOME=$(ls -d /c/mktorrent*)
export MKTORRENT_HOME="$MKTORRENT_HOME"
export PATH="$PATH:$MKTORRENT_HOME/bin/"
fi
if [[ -n "$IS_WSL" || -n "$WSL_DISTRO_NAME" ]]; then
PATH="$PATH:/c/Program Files (x86)/Windows Kits/10/App Certification Kit/"

24
darklight.css Normal file
View File

@ -0,0 +1,24 @@
/* edgar darklight CSS file */
#checkboxDarkLight:checked + .container {
background-color: #202020;
filter: invert(100%);
}
#checkboxDarkLight{
appearance: none;
width: 80px;
height: 40px;
background: black;
border-radius: 22px;
cursor: pointer;
outline: none;
}
#checkboxDarkLight::before{
content: '';
width: 40px;
height: 35px;
background-color:white;
border-radius: 35px;
cursor: pointer;
transition: .3s linear;
}

553
docs/GOALS.html Normal file
View File

@ -0,0 +1,553 @@
<html>
<head>
<title>
I2P Easy-Install...
</title>
<meta name="author" content="eyedeekay" />
<meta name="description" content="i2p.firefox" />
<meta name="keywords" content="master" />
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="showhider.css" />
<link rel="stylesheet" type="text/css" href="darklight.css" />
</head>
<body>
<input type="checkbox" id="checkboxDarkLight">
<div class="container">
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="LICENSE.html">
LICENSE
</a>
</li>
<li>
<a href="index.html">
index.html
</a>
</li>
<li>
<a href="GOALS.html">
GOALS
</a>
</li>
<li>
<a href="PRINCIPLES.html">
PRINCIPLES
</a>
</li>
<li>
<a href="RELEASE.html">
RELEASE
</a>
</li>
<li>
<a href="UPDATES.html">
UPDATES
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
</div>
</div>
</div>
<a id="returnhome" href="/">
/
</a>
<h1>
Feature Goals
</h1>
<p>
For information about the &ldquo;Goals guiding the Goals&rdquo; see:
<code>
[PRINCIPLES]
</code>
.
</p>
<p>
While Windows is the primary platform, some goals may represent cross-platform
utility as well. Since a portable jpackage really only needs slightly different
arguments on different platforms, cross-platform support is often low-cost.
</p>
<ul>
<li>
<strong>
See Also:
</strong>
</li>
<li>
<em>
Browser Integrations are provided by browser extensions which are contained in their own repositories.
</em>
</li>
<li>
Firefox:
</li>
<li>
<a href="http://git.idk.i2p/idk/I2P-in-Private-Browsing-Mode-Firefox/">
git.idk.i2p/idk/I2P-in-Private-Browsing-Mode-Firefox
</a>
</li>
<li>
<a href="https://i2pgit.org/idk/I2P-in-Private-Browsing-Mode-Firefox/">
i2pgit.org/idk/I2P-in-Private-Browsing-Mode-Firefox
</a>
</li>
<li>
<a href="https://github.com/eyedeekay/I2P-in-Private-Browsing-Mode-Firefox/">
github.com/eyedeekay/I2P-in-Private-Browsing-Mode-Firefox
</a>
</li>
<li>
Chromium:
</li>
<li>
<a href="http://git.idk.i2p/idk/I2P-Configuration-For-Chromium/">
git.idk.i2p/idk/I2P-Configuration-For-Chromium
</a>
</li>
<li>
<a href="https://i2pgit.org/idk/I2P-Configuration-For-Chromium/">
i2pgit.org/idk/I2P-Configuration-For-Chromium
</a>
</li>
<li>
<a href="https://github.com/eyedeekay/I2P-Configuration-For-Chromium/">
github.com/eyedeekay/I2P-Configuration-For-Chromium
</a>
</li>
<li>
<em>
Browser profile management are provided by a freestanding, cross-platform library which is contained in its own repository.
</em>
</li>
<li>
<a href="http://git.idk.i2p/idk/i2p.plugins.firefox">
git.idk.i2p/idk/i2p.plugins.firefox
</a>
</li>
<li>
<a href="https://i2pgit.org/idk/i2p.plugins.firefox">
i2pgit.org/idk/i2p.plugins.firefox
</a>
</li>
<li>
<a href="https://github.com/eyedeekay/i2p.plugins.firefox">
github.com/eyedeekay/i2p.plugins.firefox
</a>
</li>
</ul>
<h2>
Build Methods
</h2>
<ul>
<li>
<code>
[X]
</code>
Cleanly separate jpackage generation phase from NSIS generation phase
</li>
<li>
<code>
[X]
</code>
Enable archive builds for generating Windows
<code>
.exe
</code>
&rsquo;s from Linux hosts
</li>
</ul>
<h2>
Installation Methods
</h2>
<ul>
<li>
<code>
[X]
</code>
NSIS installer
</li>
<li>
<code>
[X]
</code>
Portable, directory-based install
</li>
<li>
<code>
[ ]
</code>
Windows Service Support
</li>
</ul>
<h2>
Update Methods
</h2>
<ul>
<li>
<code>
[X]
</code>
NSIS installer in Default Directory
</li>
<li>
<code>
[X]
</code>
NSIS installer in Portable Directory
</li>
<li>
<code>
[X]
</code>
Handle admin and non-admin updates automatically
</li>
<li>
<code>
[ ]
</code>
Zip-Only portable updater
</li>
</ul>
<h2>
Launcher
</h2>
<ul>
<li>
<code>
[X]
</code>
Detect and handle un-bundled routers on the host system, policy of non-interference
</li>
<li>
<code>
[X]
</code>
Wait for router console to be ready to launch router-console browser
</li>
<li>
<code>
[X]
</code>
Wait for proxy to be ready to launch I2P Web Browser
</li>
<li>
<code>
[X]
</code>
Launch browser instead of router when a repeat-launch is detected
</li>
<li>
<code>
[X]
</code>
GUI component for launching each available component
</li>
<li>
<code>
[X]
</code>
Introduce
<code>
browser.properties
</code>
for customization
</li>
<li>
<code>
[ ]
</code>
Registry-based browser discovery
<a href="http://git.idk.i2p/idk/i2p.plugins.firefox/-/issues/3">
Firefox
</a>
<a href="http://git.idk.i2p/idk/i2p.plugins.firefox/-/issues/4">
Chromium
</a>
</li>
</ul>
<h2>
Browser Configuration All
</h2>
<ul>
<li>
<code>
[X]
</code>
Use identical extensions in Firefox-based and Chromium-based browsers wherever possible
</li>
<li>
<code>
[X]
</code>
Always use a dedicated, I2P Easy-Install specific profile directory
</li>
<li>
<code>
[X]
</code>
Always configure an HTTP Proxy, and safe access to the router console
</li>
<li>
<code>
[X]
</code>
Provide I2P-Specific integrations to the browser UI through WebExtensions
</li>
<li>
<code>
[X]
</code>
Operate in &ldquo;Strict&rdquo; mode where the maximum level of defenses are up
</li>
<li>
<code>
[X]
</code>
Operate in &ldquo;Usability&rdquo; mode where defense is balanced with utility
</li>
<li>
<code>
[X]
</code>
Operate in &ldquo;App&rdquo; mode where we work as a single-purpose window where it is hard to access arbitrary, potentially malicious resources
</li>
<li>
<code>
[X]
</code>
All I2P-Specific profiles should be possible to generate automatically, sight-unseen
</li>
</ul>
<h2>
Browser Configuration Firefox
</h2>
<ul>
<li>
<code>
[X]
</code>
When using Firefox, download extension updates automatically, from AMO, using an outproxy
</li>
<li>
<code>
[X]
</code>
Integrate I2P in Private Browsing for to provide UI for I2P within Firefox
</li>
<li>
<code>
[X]
</code>
Prevent WebRTC proxy escapes by setting mode
<code>
4
</code>
<code>
disable_non_proxied_udp
</code>
or higher
</li>
<li>
<code>
[X]
</code>
Customize panel for Firefox
<code>
App
</code>
mode(Not required for Chromiums)
</li>
</ul>
<h2>
Browser Configuration Chromium
</h2>
<ul>
<li>
<code>
[X]
</code>
When using Chromium, load extensions from source and freeze them without updates to prevent unproxied updating.
</li>
<li>
<code>
[X]
</code>
Integrate
<code>
I2PChrome.js
</code>
to provide UI for I2P within Chrome
</li>
<li>
<code>
[X]
</code>
Prevent WebRTC proxy escapes by setting mode
<code>
4
</code>
<code>
disable_non_proxied_udp
</code>
</li>
</ul>
<h2>
Browser Configuration Strict Mode
</h2>
<ul>
<li>
<code>
[X]
</code>
Disable Javascript by default with NoScript
</li>
<li>
<code>
[X]
</code>
Enforce HTTPS where available with HTTPS Everywhere
<strong>
OR
</strong>
HTTPS only Mode
</li>
<li>
<code>
[ ]
</code>
Proactively enumerate and disable &ldquo;Fine&rdquo; fingerprinting vectors where possible(ongoing)
</li>
<li>
<code>
[ ]
</code>
When running in Tor Browser, look as much like Tor Browser as possible but use an outproxy(ongoing)
</li>
</ul>
<h2>
Browser Configuration Usability Mode
</h2>
<ul>
<li>
<code>
[X]
</code>
Enable Javascript by default but limit it with jShelter
</li>
<li>
<code>
[X]
</code>
Enforce HTTPS where available with HTTPS Everywhere
<strong>
OR
</strong>
HTTPS only Mode
</li>
<li>
<code>
[X]
</code>
Limit attempts to fetch useless junk like advertising with an up-to-date uBlock Origin
</li>
<li>
<code>
[X]
</code>
Limit attempts to reach clearnet CDN&rsquo;s with LocalCDN
</li>
<li>
<code>
[X]
</code>
Isolate
<code>
.onion
</code>
traffic from
<code>
outproxy
</code>
traffic and
<code>
.i2p
</code>
traffic using Onion in Container Tabs
</li>
</ul>
<div id="sourcecode">
<span id="sourcehead">
<strong>
Get the source code:
</strong>
</span>
<ul>
<li>
<a href="https://github.com/eyedeekay/i2p.firefox">
Source Repository: (https://github.com/eyedeekay/i2p.firefox)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
</a>
<div id="show">
<div id="hide">
<pre><code>Copyright 2018
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</code></pre>
<a href="#hide">
Hide license
</a>
</div>
</div>
</div>
</div>
<div>
<iframe src="https://snowflake.torproject.org/embed.html" width="320" height="240" frameborder="0" scrolling="no"></iframe>
</div>
<div>
<a href="https://geti2p.net/">
<img class="i2plogo" src="i2plogo.png"></img>
I2P
</a>
</div>
</body>
</html>

377
docs/PRINCIPLES.html Normal file
View File

@ -0,0 +1,377 @@
<html>
<head>
<title>
I2P Easy-Install...
</title>
<meta name="author" content="eyedeekay" />
<meta name="description" content="i2p.firefox" />
<meta name="keywords" content="master" />
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="showhider.css" />
<link rel="stylesheet" type="text/css" href="darklight.css" />
</head>
<body>
<input type="checkbox" id="checkboxDarkLight">
<div class="container">
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="LICENSE.html">
LICENSE
</a>
</li>
<li>
<a href="index.html">
index.html
</a>
</li>
<li>
<a href="GOALS.html">
GOALS
</a>
</li>
<li>
<a href="PRINCIPLES.html">
PRINCIPLES
</a>
</li>
<li>
<a href="RELEASE.html">
RELEASE
</a>
</li>
<li>
<a href="UPDATES.html">
UPDATES
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
</div>
</div>
</div>
<a id="returnhome" href="/">
/
</a>
<h1>
Guidance
</h1>
<p>
This document explains the ideas which are guiding the development of
features specific to the I2P Easy-Install bundle.
</p>
<p>
The general idea is that it is possible, on most platforms, to make I2P
post-install configuration much simpler and much less error-prone. Each
section of this document has guidance for a different &ldquo;Meta-Feature&rdquo; of
the I2P Easy-Install Bundle. For granular, specific information about
goals both achieved and un-achieved see
<code>
[GOALS]
</code>
.
</p>
<ul>
<li>
<strong>
Sections:
</strong>
</li>
</ul>
<ol>
<li>
Guidance for Browser Profile Configuration
</li>
</ol>
<h2>
Guidance for Browser Profile Configuration
</h2>
<ul>
<li>
<strong>
See also:
</strong>
</li>
<li>
<a href="http://git.idk.i2p/idk/i2p.plugins.firefox">
git.idk.i2p/idk/i2p.plugins.firefox
</a>
</li>
<li>
<a href="https://i2pgit.org/idk/i2p.plugins.firefox">
i2pgit.org/idk/i2p.plugins.firefox
</a>
</li>
<li>
<a href="https://github.com/eyedeekay/i2p.plugins.firefox">
github.com/eyedeekay/i2p.plugins.firefox
</a>
</li>
</ul>
<p>
The I2P Easy-Install Bundle for Windows considers basic configuration tasks
&ldquo;Features&rdquo; when they can be automated. The quintessential example of this
is
<strong>
<code>
Browser Profile Configuration
</code>
</strong>
where it injects settings into a
pre-existing browser from the host system. Solving this problem pre-dates
the evolution of
<code>
i2p.firefox
</code>
into a fully-fledged I2P router distribution
and has been the defining goal of this project for its entire existence.
</p>
<p>
However, what good browser profile configuration is, is as complicated as
how to deploy it. I2P has a unique opportunity to decide how it will handle
problems related to browsing in its own context while the network grows
and synthesize a useful number of safe browser configurations while also
reducing existing browser config fragmentation.
</p>
<p>
Easy-Install attempts to limit the number of &ldquo;Coarse Fingerprints&rdquo; which it will
produce by default to a predictable number. A Coarse Fingerprint is basically
a fingerprint &ldquo;That we know we&rsquo;re making&rdquo; by offering the ability to configure
something differently.
</p>
<ul>
<li>
<strong>
That means:
</strong>
</li>
</ul>
<ol>
<li>
It considers the browser integral to the interactive use of the I2P network by a large fraction of users.
</li>
<li>
It considers effective browser configuration
<strong>
impossible for a single user to achieve
</strong>
because effective browser configuration must have the characteristic of being reflected en-masse(anti-fingerprinting measures are only remotely effective when widely used).
</li>
<li>
The browser profile it injects inherits the runtime security characteristics of the
<strong>
host browser
</strong>
.
</li>
<li>
The browser profile it injects obtains runtime privacy characteristics of the
<strong>
easy-install bundle
</strong>
</li>
<li>
The number of coarse browser fingerprint sets is reduced from indeterminately large to
<code>
[supported browsers]*[variant configurations]
</code>
</li>
<li>
It attempts to balance flexibility with privacy, and accommodate people&rsquo;s preferences where possible.
</li>
<li>
It considers browser vendors better at providing browser updates than the I2P Project
</li>
</ol>
<h2>
Browser Configurations and Coarse Fingerprints
</h2>
<p>
At this time it offers configuration for Tor Browser, Firefox, Waterfox, and
LibreWolf for Firefox-based browsers, and Ungoogled-Chromium, Chromium, Brave,
Chrome, and Edgium configuration for Chromium-based browsers. That is a total
of
<strong>
Nine(9)
</strong>
main browsers. There are
<strong>
Two(2)
</strong>
variant configurations,
which correspond to &ldquo;Strict&rdquo; and &ldquo;Usability&rdquo; Modes. That makes a total of
<strong>
Eighteen(18)
</strong>
coarse browser fingerprints produced by this bundle. It also
has the ability to launch in a &ldquo;Restricted to Apps&rdquo; mode where it is only
possible to visit I2P sites using links on the I2P application interface(router
console, hidden services manager) itself.
</p>
<h3>
Strict Mode
</h3>
<p>
This is not on its face as good as having an almost entirely unified browser
fingerprint like Tor Browser attempts to have. It is a simple fact that 18
is greater than one. Every active attempt to gain granularity from a browser
outside of off-the-shelf Fingerprinting techniques is classified as &ldquo;Fine&rdquo;
fingerprinting. It is unpredictable, and harder to defend against, more likely
to exhibit novelty, and more likely to be affected by the host browser&rsquo;s
security. When fingerprinters get this creative disabling Javascript by default
is the most complete defense. This is the primary characteristic of Strict Mode,
it disables Javascript by default with NoScript.
<strong>
Strict Mode is the only
</strong>
<strong>
partial defense against fine-fingerprinting offered by this product.
</strong>
Even
disabling Javascript does not close all fine fingerprinting vectors, but it
does close most of them and reduce attack surface significantly. It is recommended
in combination with Tor Browser, and attempts to be somewhat closer to Tor Browser
than Usability Mode. It is the default mode of operation.
</p>
<h3>
Usability Mode
</h3>
<p>
In contrast to Strict Mode, Usability mode offers the greatest agreeable number
of browser features enabled by default, including a restricted subset of Javascript.
It makes no attempt at all to look like Tor Browser, even when using Tor Browser
as a host browser. It does attempt to optimize the browser for use within I2P, including
specific optimizations to keep traffic in-network or even retrieve information which is
stored on the localhost(while avoiding cache timing attacks). It does this by deploying
an alternative loadout of extensions, including ones which block advertising by default
and which include a cache of CDN resources in local browser storage.
</p>
<h3>
Firefox-Based Browsers
</h3>
<p>
Because of the relatively high configurability of Firefox-based browser
telemetry, Firefox-based browsers are preferred over Chromium-based browsers.
Chromium-based browsers will be used by default
<strong>
only
</strong>
if a Firefox based
browser is unavailable. Only Firefox-variant releases of the Extended Support
Release or of the latest stable release are supportable. If a variant lags
behind Firefox releases, it will be dropped. The primary reason for the default
&ldquo;Ordering&rdquo; of Firefox Profile Selection is the speed at which updates can be
expected to be applied.
</p>
<h3>
Chromium-Based Browsers
</h3>
<p>
Chromium-based browser selection is more subjective and slightly more ad-hoc.
Chromium browsers are chosen based on the variant&rsquo;s stated goals and perceived
efficacy in pursuing those goals. For example, if a Chromium distribution is
focused on removing telemetry or providing anti-fingerprinting, it is chosen
before a Chromium that is provided by Google or integrated tightly with the
host OS. This is a matter of judgement on my part and if you disagree you should
open an issue and argue with me. I&rsquo;m not infallible, I&rsquo;ll listen.
</p>
<h3>
All other browsers
</h3>
<p>
With all other browsers attempts at anti-fingerprinting are a moot point. It offers
limited configuration options using widely-supported generic browser configuration
means. If it doesn&rsquo;t recognize a Firefox or Chromium browser on the host, then it
sets the common proxy environment variables
<code>
http_proxy
</code>
<code>
https_proxy
</code>
<code>
ALL_PROXY
</code>
and
<code>
NO_PROXY
</code>
to their appropriate values before launching the browser configuration
and attempts to set a directory for the runtime configuration(Profile) by changing
to the profile directory.
</p>
<div id="sourcecode">
<span id="sourcehead">
<strong>
Get the source code:
</strong>
</span>
<ul>
<li>
<a href="https://github.com/eyedeekay/i2p.firefox">
Source Repository: (https://github.com/eyedeekay/i2p.firefox)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
</a>
<div id="show">
<div id="hide">
<pre><code>Copyright 2018
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</code></pre>
<a href="#hide">
Hide license
</a>
</div>
</div>
</div>
</div>
<div>
<iframe src="https://snowflake.torproject.org/embed.html" width="320" height="240" frameborder="0" scrolling="no"></iframe>
</div>
<div>
<a href="https://geti2p.net/">
<img class="i2plogo" src="i2plogo.png"></img>
I2P
</a>
</div>
</body>
</html>

221
docs/RELEASE.html Normal file
View File

@ -0,0 +1,221 @@
<html>
<head>
<title>
I2P Easy-Install...
</title>
<meta name="author" content="eyedeekay" />
<meta name="description" content="i2p.firefox" />
<meta name="keywords" content="master" />
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="showhider.css" />
<link rel="stylesheet" type="text/css" href="darklight.css" />
</head>
<body>
<input type="checkbox" id="checkboxDarkLight">
<div class="container">
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="LICENSE.html">
LICENSE
</a>
</li>
<li>
<a href="index.html">
index.html
</a>
</li>
<li>
<a href="GOALS.html">
GOALS
</a>
</li>
<li>
<a href="PRINCIPLES.html">
PRINCIPLES
</a>
</li>
<li>
<a href="RELEASE.html">
RELEASE
</a>
</li>
<li>
<a href="UPDATES.html">
UPDATES
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
</div>
</div>
</div>
<a id="returnhome" href="/">
/
</a>
<h1>
I2P Easy-Install Bundle for Windows 2.4.9
</h1>
<p>
This is a pre-release of the I2P Easy-Install Bundle for Windows.
This changes how the I2P bundle and browser profile manager are installed and integrated with the host system.
The Easy-Install bundle is now a &ldquo;portable&rdquo; system that can be moved to different locations within or between Windows file-systems while retaining all built-in functionality.
A shortcut for starting the I2P router is still provided by the installer for convenience, but the shortcuts for starting the I2P Browser are now integrated with the I2P desktop UI.
</p>
<p>
The browser profile manager itself has been split away from the monolithic I2P router+Java/jpackage, and moved into an I2P plugin managed by the router.
While this was done primarily to reduce how complex the existing code was, this also results in behavior which is closer to the main distribution of I2P for Windows and will lead to a more flexible installer, which can bundle additional default plugins and may be suitable for installation as a Windows service.
I2P Plugins can also be updated independently of the router that hosts them, so it will be possible to update the browser profile manager independently of the router itself.
It also means that the browser profile manager can be un-installed by uninstalling the plugin, and much more importantly that the browser profile manager is now compatible with all Java I2P distributions.
</p>
<p>
<strong>
Why a dev build 3 weeks before the release?
</strong>
</p>
<p>
By further delineating the components of the bundle, these changes also affected how the release process happens.
In particular the build process of each component has been encapsulated in a CI description which can be reproduced on a local PC.
This simplifies and automates the build process by ensuring that up-to-date build tools are installed in a brand-new container for every build.
In effect this should speed up the release process for I2P Easy-Install for Windows considerably.
This release is a test-run of the new process, so I can document what is going on.
It breaks down roughly like this:
</p>
<ul>
<li>
It takes ~22 minutes to compile all the targets for the
<code>
i2p.plugins.firefox
</code>
and make the resulting artifacts available. During this process, I must insert 1 HSM and enter 1 password. (This part used to be about 30 steps, now it takes 1)
</li>
<li>
It takes ~22 minutes to compile all the targets for the
<code>
i2p.firefox
</code>
project and make the resulting artifacts available. This process produces only unsigned artifacts identified by their hashes, and is non-interactive. (This part used to be around 60 steps the first time, and 40 steps each additional time)
</li>
<li>
<code>
i2p.firefox
</code>
updates are signed in their
<code>
.su3
</code>
form. The
<code>
NSIS
</code>
-powered
<code>
.exe
</code>
installer is the current updater. The next step is to sign
<em>
just this installer
</em>
and generate a torrent of the result. (This process used to depend on the previous build process and couldn&rsquo;t be done independently. Now it takes about 30 seconds)
</li>
<li>
Generate and sign a newsfeed to notify the users of an update. This process is the only process that is
<strong>
slower
</strong>
when containerized, because there are dozens of feeds to be signed in their respective containers. It takes about an hour.
</li>
</ul>
<p>
For you the end user, nothing much should change.
You&rsquo;ll get your updates a lot faster, and have more options available for testing.
The same installer is used for the updater, and the process is handled the same way.
However for developers, testers, and maintainers, this release will result in big changes for the better.
</p>
<p>
This release still embeds a
<code>
2.4.0
</code>
Java I2P router. No changes have been made to update the embedded router.
Network behavior will be unchanged until the official
<code>
2.5.0
</code>
release.
</p>
<div id="sourcecode">
<span id="sourcehead">
<strong>
Get the source code:
</strong>
</span>
<ul>
<li>
<a href="https://github.com/eyedeekay/i2p.firefox">
Source Repository: (https://github.com/eyedeekay/i2p.firefox)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
</a>
<div id="show">
<div id="hide">
<pre><code>Copyright 2018
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</code></pre>
<a href="#hide">
Hide license
</a>
</div>
</div>
</div>
</div>
<div>
<iframe src="https://snowflake.torproject.org/embed.html" width="320" height="240" frameborder="0" scrolling="no"></iframe>
</div>
<div>
<a href="https://geti2p.net/">
<img class="i2plogo" src="i2plogo.png"></img>
I2P
</a>
</div>
</body>
</html>

3
docs/RELEASE.md Normal file
View File

@ -0,0 +1,3 @@
# I2P Easy-Install 2.8.0
This release updates the embedded I2P router to I2P 2.8.0.

182
docs/UPDATES.html Normal file
View File

@ -0,0 +1,182 @@
<html>
<head>
<title>
I2P Easy-Install...
</title>
<meta name="author" content="eyedeekay" />
<meta name="description" content="i2p.firefox" />
<meta name="keywords" content="master" />
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="showhider.css" />
<link rel="stylesheet" type="text/css" href="darklight.css" />
</head>
<body>
<input type="checkbox" id="checkboxDarkLight">
<div class="container">
<div id="navbar">
<a href="#shownav">
Show navigation
</a>
<div id="shownav">
<div id="hidenav">
<ul>
<li>
<a href="..">
Up one level ^
</a>
</li>
<li>
<a href="index.html">
index
</a>
</li>
<li>
<a href="LICENSE.html">
LICENSE
</a>
</li>
<li>
<a href="index.html">
index.html
</a>
</li>
<li>
<a href="GOALS.html">
GOALS
</a>
</li>
<li>
<a href="PRINCIPLES.html">
PRINCIPLES
</a>
</li>
<li>
<a href="RELEASE.html">
RELEASE
</a>
</li>
<li>
<a href="UPDATES.html">
UPDATES
</a>
</li>
</ul>
<br>
<a href="#hidenav">
Hide Navigation
</a>
</div>
</div>
</div>
<a id="returnhome" href="/">
/
</a>
<h1>
Setting up an Update Server for an I2P Bundle
</h1>
<p>
It is important to set up a signed update server so that people are able to
safely and anonymously update your I2P bundle. There are two sort of &ldquo;Levels&rdquo;
to what you might do to provide updates to your users. Each of them requires the
generation of a
<a href="https://eyedeekay.github.io/Hopefully-Holistic-Guide-to-I2P-Dev-Build-Update-Hosting/">
signed newsfeed
</a>
,
which also serves as a way to provide information to your users about updates,
features, and security events.
</p>
<p>
This project,
<code>
i2p.firefox
</code>
a.k.a. the &ldquo;I2P Easy Install Bundle&rdquo; uses the &ldquo;Executable&rdquo;
update subtype, meaning that it capable of installing itself by executing code as the
user who runs the update, which is usually the main user of a Windows 10 or 11 PC.
This update subtype is highly flexible, but requires the creation of a &ldquo;Scripted&rdquo; using
something like
<code>
NSIS
</code>
,
<code>
wixl
</code>
, or custom code. Other update types include ZIP (used by
the core I2P product) and DMG(used by Mac OSX).
</p>
<h1>
Static HTTP Update URL over I2P
</h1>
<h1>
Bittorrent Update URL over I2P
</h1>
<p>
<a href="https://github.com/i2p/i2p.plugins.zzzot">
If you choose to do this, consider using zzzot to host your open tracker instead of a normal site
</a>
,
which you can obtain from
<a href="http://stats.i2p/i2p/plugins/zzzot.su3">
this I2P link
</a>
.
</p>
<div id="sourcecode">
<span id="sourcehead">
<strong>
Get the source code:
</strong>
</span>
<ul>
<li>
<a href="https://github.com/eyedeekay/i2p.firefox">
Source Repository: (https://github.com/eyedeekay/i2p.firefox)
</a>
</li>
</ul>
</div>
<div>
<a href="#show">
Show license
</a>
<div id="show">
<div id="hide">
<pre><code>Copyright 2018
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</code></pre>
<a href="#hide">
Hide license
</a>
</div>
</div>
</div>
</div>
<div>
<iframe src="https://snowflake.torproject.org/embed.html" width="320" height="240" frameborder="0" scrolling="no"></iframe>
</div>
<div>
<a href="https://geti2p.net/">
<img class="i2plogo" src="i2plogo.png"></img>
I2P
</a>
</div>
</body>
</html>

25
docs/UPDATES.md Normal file
View File

@ -0,0 +1,25 @@
Setting up an Update Server for an I2P Bundle
=============================================
It is important to set up a signed update server so that people are able to
safely and anonymously update your I2P bundle. There are two sort of "Levels"
to what you might do to provide updates to your users. Each of them requires the
generation of a [signed newsfeed](https://eyedeekay.github.io/Hopefully-Holistic-Guide-to-I2P-Dev-Build-Update-Hosting/),
which also serves as a way to provide information to your users about updates,
features, and security events.
This project, `i2p.firefox` a.k.a. the "I2P Easy Install Bundle" uses the "Executable"
update subtype, meaning that it capable of installing itself by executing code as the
user who runs the update, which is usually the main user of a Windows 10 or 11 PC.
This update subtype is highly flexible, but requires the creation of a "Scripted" using
something like `NSIS`, `wixl`, or custom code. Other update types include ZIP (used by
the core I2P product) and DMG(used by Mac OSX).
Static HTTP Update URL over I2P
===============================
Bittorrent Update URL over I2P
==============================
[If you choose to do this, consider using zzzot to host your open tracker instead of a normal site](https://github.com/i2p/i2p.plugins.zzzot),
which you can obtain from [this I2P link](http://stats.i2p/i2p/plugins/zzzot.su3).

24
docs/darklight.css Normal file
View File

@ -0,0 +1,24 @@
/* edgar darklight CSS file */
#checkboxDarkLight:checked + .container {
background-color: #202020;
filter: invert(100%);
}
#checkboxDarkLight{
appearance: none;
width: 80px;
height: 40px;
background: black;
border-radius: 22px;
cursor: pointer;
outline: none;
}
#checkboxDarkLight::before{
content: '';
width: 40px;
height: 35px;
background-color:white;
border-radius: 35px;
cursor: pointer;
transition: .3s linear;
}

BIN
docs/i2plogo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

15
docs/showhider.css Normal file
View File

@ -0,0 +1,15 @@
/* edgar showhider CSS file */
#show {display:none; }
#hide {display:block; }
#show:target {display: block; }
#hide:target {display: none; }
#shownav {display:none; }
#hidenav {display:block; }
#shownav:target {display: block; }
#hidenav:target {display: none; }
#donate {display:none; }
#hidedonate {display:block; }
#donate:target {display: block; }
#hidedonate:target {display: none; }

163
docs/style.css Normal file
View File

@ -0,0 +1,163 @@
/* edgar default CSS file */
body {
font-family: "Roboto";
font-family: monospace;
text-align: justify;
background-color: #373636;
color: whitesmoke;
font-size: 1.15em;
}
ul {
width: 55%;
display: block;
}
ol {
width: 55%;
display: block;
}
li {
margin-top: 1%;
}
p {
max-width: 90%;
margin-top: 1%;
margin-left: 3%;
margin-right: 3%;
}
img {
float: left;
top: 5%;
left: 5%;
max-width: 60%;
display: inline;
padding-right: 2%;
}
.inline {
display: inline;
}
.link-button:focus {
outline: none;
}
.link-button:active {
color: red;
}
code {
font-family: monospace;
border-radius: 5%;
padding: 1%;
border-color: darkgray;
font-size: .9em;
}
a {
color: #C6D9FE;
padding: 1%;
}
ul li {
color: #C6D9FE;
}
iframe {
background: aliceblue;
border-radius: 15%;
margin: 2%;
}
.container {
display: inline-block;
margin: 0;
padding: 0;
}
.editor-toolbar a {
display: inline-block;
text-align: center;
text-decoration: none !important;
color: whitesmoke !important;
}
#feed {
width: 60vw;
height: unset !important;
margin: 0;
padding: 0;
float: right;
background-color: #373636;
color: whitesmoke;
border: #C6D9FE solid 1px;
}
.thread-post,
.thread {
color: whitesmoke !important;
background-color: #373636;
border: 1px solid darkgray;
font-size: inherit;
padding-top: 1%;
padding-bottom: 1%;
}
.thread-post {
margin-left: 4%;
}
input {
text-align: center;
color: whitesmoke !important;
background-color: #373636;
border: 1px solid darkgray;
font: normal normal normal 14px/1 FontAwesome;
font-size: inherit;
padding-top: 1%;
padding-bottom: 1%;
}
.thread-hash {
text-align: right;
color: whitesmoke !important;
background-color: #373636;
border: 1px solid darkgray;
font-size: inherit;
padding-top: 1%;
padding-bottom: 1%;
}
.post-body {
text-align: left;
color: whitesmoke !important;
font-size: inherit;
padding-top: 1%;
padding-bottom: 1%;
}
#show {display:none; }
#hide {display:block; }
#show:target {display: block; }
#hide:target {display: none; }
#shownav {display:none; }
#hidenav {display:block; }
#shownav:target {display: block; }
#hidenav:target {display: none; }
#navbar {
float: right;
width: 15%;
}
#returnhome {
font-size: xxx-large;
display: inline;
}
h1 {
display: inline;
}

View File

@ -2,14 +2,38 @@
JNA_VERSION=5.12.1
export JNA_VERSION=5.12.1
I2PFIREFOX_VERSION=1.0.7
export I2PFIREFOX_VERSION=1.0.7
export GITHUB_TAG=$(git describe --tags --abbrev=0 | sed 's|i2p||g' | tr -d [a-z-])
if [ -z "$VERSIONMAJOR" ]; then
VERSIONMAJOR=$(echo "$GITHUB_TAG" | cut -d . -f 1)
fi
if [ -z "$VERSIONMINOR" ]; then
VERSIONMINOR=$(echo "$GITHUB_TAG" | cut -d . -f 2)
fi
if [ -z "$VERSIONBUILD" ]; then
VERSIONBUILD=$(echo "$GITHUB_TAG" | cut -d . -f 3)
fi
if [ -z "$VERSIONMAJOR" ]; then
I2P_VERSION="master"
export I2P_VERSION="master"
VERSION="master"
export VERSION="master"
I2PFIREFOX_VERSION="2.9.0"
export I2PFIREFOX_VERSION="2.9.0"
else
I2P_VERSION="$VERSIONMAJOR.$VERSIONMINOR.$VERSIONBUILD"
export I2P_VERSION="$VERSIONMAJOR.$VERSIONMINOR.$VERSIONBUILD"
VERSION="i2p-$I2P_VERSION"
export VERSION="i2p-$I2P_VERSION"
I2PFIREFOX_VERSION="$VERSIONMAJOR.$VERSIONMINOR.$VERSIONBUILD"
export I2PFIREFOX_VERSION="$VERSIONMAJOR.$VERSIONMINOR.$VERSIONBUILD"
fi
# Comment this out to build from an alternate branch or
# the tip of the master branch.
VERSIONMAJOR=2
VERSIONMINOR=1
VERSIONBUILD=0
I2P_VERSION="$VERSIONMAJOR.$VERSIONMINOR.$VERSIONBUILD"
export I2P_VERSION="$VERSIONMAJOR.$VERSIONMINOR.$VERSIONBUILD"
VERSION=i2p-2.1.0
export VERSION=i2p-2.1.0
#VERSION=i2p-2.4.0
#export VERSION=i2p-2.4.0
echo "I2P version $I2P_VERSION"
echo "Tag $VERSION"
echo "I2P Firefox Profile version $I2PFIREFOX_VERSION"

1355
index.html

File diff suppressed because it is too large Load Diff

View File

@ -1,307 +0,0 @@
package net.i2p.router;
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.logging.FileHandler;
import java.util.logging.Logger;
import java.util.logging.SimpleFormatter;
public class CopyConfigDir extends WindowsServiceUtil {
static final Logger logger = Logger.getLogger("configlog");
public static void initLogger() {
try {
// This block configure the logger with handler and formatter
FileHandler fh = new FileHandler(logFile().toString());
logger.addHandler(fh);
SimpleFormatter formatter = new SimpleFormatter();
fh.setFormatter(formatter);
// the following statement is used to log any messages
logger.info("My first log");
} catch (SecurityException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
}
public static boolean copyDirectory(String baseDir, String workDir) {
File baseFile = new File(baseDir);
File workFile = new File(workDir);
return copyDirectory(baseFile, workFile);
}
public static boolean copyDirectory(File baseDir, File workDir) {
for (File file : baseDir.listFiles()) {
String fPath = file.getAbsolutePath().replace(
file.getParentFile().getAbsolutePath(), "");
String newPath = workDir.toString() + fPath;
if (file.isDirectory())
if (copyDirectory(file, new File(newPath)))
return false;
if (file.isFile())
if (0 == copyFile(file, new File(newPath), true))
return false;
}
return true;
}
public static boolean copyConfigDirectory(File baseDir, File workDir) {
for (File file : baseDir.listFiles()) {
// System.out.println(file.getAbsolutePath());
String fPath = file.getAbsolutePath().replace(
file.getParentFile().getAbsolutePath(), "");
String newPath = workDir.toString() + fPath;
if (file.isDirectory())
if (!copyConfigDirectory(file, new File(newPath)))
return false;
if (file.isFile()) {
int cnr = copyFileNeverOverwrite(file, new File(newPath));
if (0 == cnr)
return false;
if (1 == cnr) {
logger.info(
"using jpackaged configs in a jpackaged install, creating jpackaged file");
File jpackagedConfigsInUse = new File(appImageHome(), "jpackaged");
if (!jpackagedConfigsInUse.exists()) {
try {
jpackagedConfigsInUse.createNewFile();
} catch (IOException e) {
logger.warning(
"Error creating jpackaged file, delete config files manually when uninstalling");
}
}
}
if (-1 == cnr) {
logger.info(
"not overwriting existing config file, not creating jpackaged file");
}
}
}
return true;
}
public static int copyFileNeverOverwrite(String basePath, String workPath) {
File baseFile = new File(basePath);
File workFile = new File(workPath);
return copyFileNeverOverwrite(baseFile, workFile);
}
public static int copyFileNeverOverwrite(File basePath, File workPath) {
return copyFile(basePath, workPath, false);
}
public static int copyFile(File basePath, File workPath, boolean overWrite) {
if (!basePath.exists()) {
logger.info(basePath.getAbsolutePath() + " doesn't exist, not copying");
return 0;
}
if (!overWrite && workPath.exists()) {
logger.info(workPath.getAbsolutePath() +
" already exists, not overwriting");
return -1;
}
File workDir = workPath.getParentFile();
if (!workDir.exists()) {
workDir.mkdirs();
}
try (InputStream in =
new BufferedInputStream(new FileInputStream(basePath));
OutputStream out =
new BufferedOutputStream(new FileOutputStream(workPath))) {
byte[] buffer = new byte[1024];
int lengthRead;
while ((lengthRead = in.read(buffer)) > 0) {
out.write(buffer, 0, lengthRead);
out.flush();
}
in.close();
out.close();
return 1;
} catch (Throwable e) {
logger.warning(e.toString());
logger.warning("failed to copy " + basePath.getAbsolutePath() + " to " +
workPath.getAbsolutePath());
return 0;
}
}
protected 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);
}
}
File i2p = appImageHome();
logger.info("Checking for signs of life in I2P_CONFIG directory: " + i2p);
return i2p;
}
protected 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);
}
}
File i2p = appImageHome();
logger.info("Checking for signs of life in I2P directory: " + i2p);
return i2p;
}
/**
* get the path to the java home, for jpackage this is related to the
* executable itself, which is handy to know. It's a directory called runtime,
* relative to the root of the app-image on each platform:
*
* Windows - Root of appimage is 1 directory above directory named runtime
* ./runtime
*
* Linux - Root of appimage is 2 directories above directory named runtime
* ./lib/runtime
*
* Mac OSX - Unknown for now
*
* @return
*/
protected static File javaHome() {
File jrehome = new File(System.getProperty("java.home"));
if (jrehome != null) {
if (jrehome.exists()) {
return jrehome;
}
}
return null;
}
/**
* get the path to the root of the app-image root by getting the path to
* java.home and the OS, and traversing up to the app-image root based on that
* information.
*
* @return the app-image root
*/
protected static File appImageHome() {
File jreHome = javaHome();
if (jreHome != null) {
switch (osName()) {
case "windows":
return jreHome.getAbsoluteFile().getParentFile();
case "mac":
case "linux":
return jreHome.getAbsoluteFile().getParentFile().getParentFile();
}
}
return null;
}
/**
* get the path to the binary of the app-image root by getting the path to
* java.home and the OS, and traversing up to the app-image root based on that
* information, then getting the binary path on a per-platform basis. The path
* returned will be relative to the root.
*
* @return the app-image root
*/
protected static String appImageExe() {
File aih = appImageHome();
if (aih != null) {
switch (osName()) {
case "windows":
return "I2P.exe";
case "mac":
case "linux":
return "./bin/I2P";
}
}
return null;
}
/**
* get the path to the default config of the app-image by getting the path to
* java.home and the OS, and traversing up to the app-image root based on that
* information, then appending the config directory to the end onn a
* per-platform basis
*
* @return the app-image root
*/
protected static File appImageConfig() {
File aih = appImageHome();
if (aih == null) {
return null;
}
String osName = osName();
switch (osName) {
case "windows":
File winConfigDir = new File(aih, "config");
if (winConfigDir != null) {
if (winConfigDir.exists()) {
return winConfigDir;
}
}
case "mac":
case "linux":
File linConfigDir = new File(aih, "lib/config");
if (linConfigDir != null) {
if (linConfigDir.exists()) {
return linConfigDir;
}
}
}
return null;
}
protected static boolean copyConfigDir() {
File appImageConfigDir = appImageConfig();
File appImageHomeDir = selectHome();
return copyConfigDirectory(appImageConfigDir, appImageHomeDir);
}
protected static String routerConfig() {
File appImageHomeDir = selectHome();
File routerConf = new File(appImageHomeDir, "router.config");
if (routerConf != null) {
if (routerConf.exists()) {
return routerConf.getAbsolutePath();
}
}
return null;
}
/**
* set up the path to the log file
*
* @return
*/
protected static File logFile() { return logFile("launcher.log"); }
/**
* set up the path to the log file
*
* @return
*/
protected static File logFile(String p) {
File log = new File(selectProgramFile(), "logs");
if (!log.exists())
log.mkdirs();
return new File(log, p);
}
}

View File

@ -1,35 +0,0 @@
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 + ")");
}
}
}

View File

@ -0,0 +1,83 @@
package net.i2p.router;
import java.io.File;
import java.io.IOException;
import javax.swing.JOptionPane;
import net.i2p.router.RouterContext;
public class I2PAppUtil extends WindowsAppUtil {
public String ServiceUpdaterString() {
return "http://tc73n4kivdroccekirco7rhgxdg5f3cjvbaapabupeyzrqwv5guq.b32.i2p/news.su3";
}
public String ServiceBackupUpdaterString() {
return "http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news.su3";
}
public String ServiceStaticUpdaterString() {
return "http://echelon.i2p/i2p/i2pupdate.sud,http://stats.i2p/i2p/i2pupdate.sud";
}
public String getProgramFilesInstall() {
String programFiles = System.getenv("PROGRAMFILES");
if (programFiles != null) {
File programFilesI2P = new File(programFiles, "i2p/i2p.exe");
if (programFilesI2P.exists())
return programFilesI2P.getAbsolutePath();
}
String programFiles86 = System.getenv("PROGRAMFILES86");
if (programFiles86 != null) {
File programFiles86I2P = new File(programFiles86, "i2p/i2p.exe");
if (programFiles86I2P.exists())
return programFiles86I2P.getAbsolutePath();
}
return null;
}
public boolean checkProgramFilesInstall() {
String programFiles = System.getenv("PROGRAMFILES");
if (programFiles != null) {
File programFilesI2P = new File(programFiles, "i2p/i2p.exe");
if (programFilesI2P.exists())
return true;
}
String programFiles86 = System.getenv("PROGRAMFILES86");
if (programFiles86 != null) {
File programFiles86I2P = new File(programFiles86, "i2p/i2p.exe");
if (programFiles86I2P.exists())
return true;
}
return false;
}
public boolean promptUserInstallStartIfAvailable() {
if (osName() != "windows") {
return true;
}
if (checkProgramFilesInstall()) {
int a;
String message =
"It appears you have an existing, unbundled I2P rotuer installed.\n";
message +=
"However, it is not running yet. Please start it using the shortcut on the desktop.\n";
message +=
"If you click \"No\", the Easy-Install router will be launched instead.\n";
a = JOptionPane.showConfirmDialog(null, message,
"I2P Service detected not running",
JOptionPane.YES_NO_OPTION);
if (a == JOptionPane.NO_OPTION) {
// Do nothing here, this will continue on to launch a jpackaged router
return true;
} else {
try {
String pfi = getProgramFilesInstall();
if (pfi != null)
Runtime.getRuntime().exec(new String[] {pfi});
} catch (IOException e) {
return false;
}
return true;
}
}
return true;
}
}

View File

@ -1,123 +0,0 @@
package net.i2p.router;
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;
import java.util.*;
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",
});
}
}
}

View File

@ -1,27 +1,22 @@
package net.i2p.router;
import static net.i2p.update.UpdateType.*;
import java.io.*;
import java.net.InetAddress;
import java.net.ServerSocket;
import java.net.Socket;
import java.util.*;
import java.util.logging.FileHandler;
import java.util.logging.Logger;
import java.util.logging.SimpleFormatter;
import net.i2p.app.ClientAppManager;
import net.i2p.crypto.*;
import net.i2p.i2pfirefox.*;
import net.i2p.router.Router;
import net.i2p.router.RouterLaunch;
import net.i2p.update.*;
import net.i2p.update.UpdateManager;
import net.i2p.update.UpdatePostProcessor;
import net.i2p.update.UpdateType.*;
import net.i2p.util.Log;
/**
* Launches a router from %PROGRAMFILES%/I2P using configuration data in
* %LOCALAPPDATA%/I2P.. Uses Java 9 APIs.
* Launches a router from %WORKINGDIR%/I2P using configuration data in
* %WORKINGDIR%/I2P.. Uses Java 9 APIs.
*
* Sets the following properties:
* i2p.dir.base - this points to the (read-only) resources inside the bundle
@ -29,71 +24,21 @@ import net.i2p.update.UpdatePostProcessor;
* appdata
* router.pid - the pid of the java process.
*/
public class WinLauncher extends CopyConfigDir {
static WindowsUpdatePostProcessor wupp = null;
private static Router i2pRouter;
public static void main(String[] args) {
setupLauncher();
initLogger();
int privateBrowsing = 0;
boolean usabilityMode = false;
boolean chromiumFirst = false;
int proxyTimeoutTime = 200;
ArrayList<String> newArgsList = new ArrayList<String>();
if (args != null) {
if (args.length > 0) {
for (String arg : args) {
if (arg.equals("-private")) {
privateBrowsing = 1;
logger.info(
"Private browsing is true, profile will be discarded at end of session.");
} else if (arg.equals("-chromium")) {
chromiumFirst = true;
logger.info("Chromium will be selected before Firefox.");
} else if (arg.equals("-usability")) {
usabilityMode = true;
logger.info(
"Usability mode is true, using alternate extensions loadout.");
} else if (arg.equals("-noproxycheck")) {
proxyTimeoutTime = 0;
logger.info("Proxy timeout time set to zero");
} else {
// make an effort to not let people launch into sites if the proxy
// isn't quite ready yet, but also disable the proxy timeout if
// they're reaching a router console
if (arg.startsWith("http://localhost:76")) {
newArgsList.add(arg);
proxyTimeoutTime = 0;
} else if (arg.startsWith("http://127.0.0.1:76")) {
newArgsList.add(arg);
proxyTimeoutTime = 0;
} else if (arg.startsWith("https://localhost:76")) {
newArgsList.add(arg);
proxyTimeoutTime = 0;
} else if (arg.startsWith("https://127.0.0.1:76")) {
newArgsList.add(arg);
proxyTimeoutTime = 0;
} else if (proxyTimeoutTime > 0) {
newArgsList.add(arg);
} else if (!isAvailable(4444)) {
newArgsList.add(arg);
}
}
}
}
}
public class WinLauncher extends I2PAppUtil {
// private final CopyConfigDir copyConfigDir;
WinUpdatePostProcessor wupp = null;
private Router i2pRouter;
private final Log logger;
public WinLauncher() {
File programs = programFile();
File home = homeDir();
System.setProperty(
"i2p.dir.base",
new File(programs.getAbsolutePath(), "config").getAbsolutePath());
System.setProperty("i2p.dir.config", home.getAbsolutePath());
appImageConfig().getAbsolutePath());
System.setProperty("i2p.dir.config", appImageConfig().getAbsolutePath());
System.setProperty("router.pid",
String.valueOf(ProcessHandle.current().pid()));
String.valueOf(ProcessHandle.current().pid()));
/**
* IMPORTANT: You must set user.dir to the same directory where the
* jpackage is intstalled, or when the launcher tries to re-run itself
@ -101,179 +46,82 @@ public class WinLauncher extends CopyConfigDir {
* to find the JVM and Runtime bundle. This broke Windows 11 installs.
*/
System.setProperty("user.dir", programs.getAbsolutePath());
logger.info("\t" + System.getProperty("user.dir"));
logger.info("\t" + System.getProperty("i2p.dir.base"));
logger.info("\t" + System.getProperty("i2p.dir.config"));
logger.info("\t" + System.getProperty("router.pid"));
boolean continuerunning = promptServiceStartIfAvailable("i2p");
i2pRouter = new Router(routerConfig(), System.getProperties());
this.setLog(i2pRouter.getContext().logManager().getLog(WindowsAppUtil.class));
// copyConfigDir = new CopyConfigDir(i2pRouter.getContext());
logger = i2pRouter.getContext().logManager().getLog(WinLauncher.class);
}
public static void main(String[] args) {
var launcher = new WinLauncher();
launcher.setupLauncher();
int proxyTimeoutTime = 200;
launcher.logger.info("\t" + System.getProperty("user.dir"));
launcher.logger.info("\t" + System.getProperty("i2p.dir.base"));
launcher.logger.info("\t" + System.getProperty("i2p.dir.config"));
launcher.logger.info("\t" + System.getProperty("router.pid"));
boolean continuerunning = launcher.promptServiceStartIfAvailable("i2p");
if (!continuerunning) {
logger.severe(
launcher.logger.error(
"Service startup failure, please start I2P service with services.msc");
System.exit(2);
} else {
fixServiceConfig();
}
continuerunning = promptUserInstallStartIfAvailable();
continuerunning = launcher.promptUserInstallStartIfAvailable();
if (!continuerunning) {
logger.severe("User-install startup required.");
launcher.logger.error("User-install startup required.");
System.exit(2);
} else {
fixServiceConfig();
}
// This actually does most of what we use NSIS for if NSIS hasn't
// already done it, which essentially makes this whole thing portable.
if (!copyConfigDir()) {
logger.severe("Cannot copy the configuration directory");
System.exit(1);
}
/*
* if (!launcher.copyConfigDir.copyConfigDir()) {
* launcher.logger.error("Cannot copy the configuration directory");
* System.exit(1);
* }
*/
if (launchBrowser(privateBrowsing, usabilityMode, chromiumFirst,
proxyTimeoutTime, newArgsList)) {
System.exit(0);
}
i2pRouter = new Router(routerConfig(), System.getProperties());
if (!isInstalled("i2p")) {
if (i2pRouter.saveConfig("routerconsole.browser", null)) {
logger.info("removed routerconsole.browser config");
}
if (i2pRouter.saveConfig("routerconsole.browser",
appImageExe() + " -noproxycheck")) {
logger.info("updated routerconsole.browser config " + appImageExe());
if (!launcher.isInstalled("i2p")) {
if (launcher.i2pRouter.saveConfig("routerconsole.browser", "NUL")) {
launcher.logger.info("updated routerconsole.browser config " +
launcher.appImageExe());
}
}
logger.info("Router is configured");
launcher.logger.info("Router is configured");
Thread registrationThread = new Thread(REGISTER_UPP);
Thread registrationThread = new Thread(launcher.REGISTER_UPP);
registrationThread.setName("UPP Registration");
registrationThread.setDaemon(true);
registrationThread.start();
setNotStarting();
i2pRouter.runRouter();
launcher.i2pRouter.runRouter();
}
private static void fixServiceConfig() {
if (osName() != "windows")
return;
// If the user installed the Easy bundle before installing the
// IzPack installer, then they have a config file which contains the
// wrong update URL. Check for it, and change it back if necessary.
// closes #23
String routerconf = routerConfig();
if (routerconf != null) {
File routerconffile = new File(routerconf);
if (!routerconffile.exists()) {
return;
}
} else {
return;
}
if (isInstalled("i2p") || checkProgramFilesInstall()) {
i2pRouter = new Router(routerconf, System.getProperties());
String newsURL = i2pRouter.getConfigSetting("router.newsURL");
if (newsURL != null) {
if (newsURL.contains(
"http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news/win/beta/news.su3")) {
logger.info(
"checked router.newsURL config, containes win/beta in a service install, invalid update type");
if (i2pRouter.saveConfig("router.newsURL", ServiceUpdaterString())) {
logger.info("updated routerconsole.browser config " +
appImageExe());
}
}
}
String backupNewsURL = i2pRouter.getConfigSetting("router.backupNewsURL");
if (backupNewsURL != null) {
if (backupNewsURL.contains(
"http://tc73n4kivdroccekirco7rhgxdg5f3cjvbaapabupeyzrqwv5guq.b32.i2p/win/beta/news.su3")) {
logger.info(
"checked router.backupNewsURL config, containes win/beta in a service install, invalid update type");
if (i2pRouter.saveConfig("router.backupNewsURL",
ServiceBackupUpdaterString())) {
logger.info("updated routerconsole.browser config " +
appImageExe());
}
}
}
String updateURL = i2pRouter.getConfigSetting("router.updateURL");
if (updateURL != null) {
if (updateURL.contains(
"http://ekm3fu6fr5pxudhwjmdiea5dovc3jdi66hjgop4c7z7dfaw7spca.b32.i2p/i2pwinupdate.su3")) {
logger.info(
"checked router.updateURL config, containes easy-intall update in a service install, invalid update type");
if (i2pRouter.saveConfig("router.updateURL",
ServiceStaticUpdaterString())) {
logger.info("updated routerconsole.browser config " +
appImageExe());
}
}
}
}
}
private static void setupLauncher() {
private void setupLauncher() {
File jrehome = javaHome();
logger.info("jre home is: " + jrehome.getAbsolutePath());
File appimagehome = appImageHome();
logger.info("appimage home is: " + appimagehome.getAbsolutePath());
}
private static File programFile() {
File programs = selectProgramFile();
private File programFile() {
File programs = selectHome();
if (!programs.exists())
programs.mkdirs();
else if (!programs.isDirectory()) {
logger.warning(
logger.warn(
programs +
" exists but is not a directory. Please get it out of the way");
" exists but is not a directory. Please get it out of the way");
System.exit(1);
}
return programs;
}
private static File homeDir() {
File home = selectHome();
if (!home.exists())
home.mkdirs();
else if (!home.isDirectory()) {
logger.warning(
home +
" exists but is not a directory. Please get it out of the way");
System.exit(1);
}
return home;
}
private static boolean launchBrowser(int privateBrowsing,
boolean usabilityMode,
boolean chromiumFirst,
int proxyTimeoutTime,
ArrayList<String> newArgsList) {
if (i2pIsRunning()) {
logger.info("I2P is already running, launching an I2P browser");
I2PBrowser i2pBrowser = new I2PBrowser();
i2pBrowser.usability = usabilityMode;
i2pBrowser.chromiumFirst = chromiumFirst;
i2pBrowser.firefox = !chromiumFirst;
i2pBrowser.chromium = chromiumFirst;
if (chromiumFirst) {
logger.warning("favoring Chromium instead of Firefox");
}
i2pBrowser.setProxyTimeoutTime(proxyTimeoutTime);
System.out.println("I2PBrowser");
String[] newArgs = newArgsList.toArray(new String[newArgsList.size()]);
setNotStarting();
i2pBrowser.launch(privateBrowsing, newArgs);
return true;
}
return false;
}
// see
// https://stackoverflow.com/questions/434718/sockets-discover-port-availability-using-java
private static boolean isAvailable(int portNr) {
private boolean isAvailable(int portNr) {
boolean portFree;
try (var ignored = new ServerSocket(portNr)) {
portFree = true;
@ -283,94 +131,7 @@ public class WinLauncher extends CopyConfigDir {
return portFree;
}
private static boolean i2pIsRunningCheck() {
// check if there's something listening on port 7657(Router Console)
if (!isAvailable(7657))
return true;
// check if there's something listening on port 7654(I2CP)
if (!isAvailable(7654))
return true;
if (checkPing())
return true;
return false;
}
private static void setNotStarting() {
logger.info("removing startup file, the application has started");
File home = selectHome();
File starting = new File(home, "starting");
if (starting.exists()) {
starting.delete();
}
}
private static void setStarting() {
logger.info("creating startup file, router is starting up");
File home = selectHome();
File starting = new File(home, "starting");
if (!starting.exists()) {
try {
starting.createNewFile();
} catch (IOException e) {
logger.info(e.toString());
}
}
Runtime.getRuntime().addShutdownHook(new Thread() {
@Override
public void run() {
setNotStarting();
}
});
}
private static boolean checkStarting() {
logger.info("checking startup file");
File home = selectHome();
File starting = new File(home, "starting");
if (starting.exists()) {
logger.info("startup file exists, I2P is already starting up");
return true;
}
logger.info("startup file does not exist but we're running now");
setStarting();
return false;
}
// check for the existence of router.ping file, if it's less then 2
// minutes old, exit
private static boolean checkPing() {
File home = selectHome();
File ping = new File(home, "router.ping");
if (ping.exists()) {
long diff = System.currentTimeMillis() - ping.lastModified();
if (diff > 60 * 1000) {
logger.info(
"router.ping exists and is more than 1 minute old, I2P does not appear to be running.");
logger.info("If I2P is running, report this as a bug.");
return false;
} else {
return true;
}
}
return false;
}
private static boolean i2pIsRunning() {
if (checkStarting())
return true;
if (checkPing())
return true;
if (i2pIsRunningCheck())
return true;
for (int i = 0; i < 10; i++) {
if (i2pIsRunningCheck())
return true;
sleep(1000);
}
return false;
}
private static final Runnable REGISTER_UPP = () -> {
private final Runnable REGISTER_UPP = () -> {
RouterContext ctx;
while ((ctx = i2pRouter.getContext()) == null) {
sleep(1000);
@ -381,11 +142,10 @@ public class WinLauncher extends CopyConfigDir {
sleep(1000);
}
UpdateManager um;
while ((um = (UpdateManager)cam.getRegisteredApp(UpdateManager.APP_NAME)) ==
null) {
while ((um = (UpdateManager) cam.getRegisteredApp(UpdateManager.APP_NAME)) == null) {
sleep(1000);
}
WindowsUpdatePostProcessor wupp = new WindowsUpdatePostProcessor(ctx);
WinUpdatePostProcessor wupp = new WinUpdatePostProcessor(ctx);
um.register(wupp, UpdateType.ROUTER_SIGNED_SU3, SU3File.TYPE_EXE);
um.register(wupp, UpdateType.ROUTER_DEV_SU3, SU3File.TYPE_EXE);
};
@ -395,7 +155,7 @@ public class WinLauncher extends CopyConfigDir {
*
* @param millis
*/
private static void sleep(int millis) {
private void sleep(int millis) {
try {
Thread.sleep(millis);
} catch (InterruptedException bad) {

View File

@ -16,7 +16,7 @@ import net.i2p.update.UpdateType;
import net.i2p.util.Log;
import net.i2p.util.SystemVersion;
public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
public class WinUpdatePostProcessor implements UpdatePostProcessor {
private final Log _log;
private final RouterContext ctx;
private final AtomicBoolean hook = new AtomicBoolean();
@ -26,17 +26,21 @@ public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
private volatile File positionedFile = null;
WindowsUpdatePostProcessor(RouterContext ctx) {
WinUpdatePostProcessor(RouterContext ctx) {
this.ctx = ctx;
this._log = ctx.logManager().getLog(WindowsUpdatePostProcessor.class);
this._log = ctx.logManager().getLog(WinUpdatePostProcessor.class);
}
public String getVersion() { return version; }
public String getVersion() {
return version;
}
public File getFile() { return positionedFile; }
public File getFile() {
return positionedFile;
}
public void updateDownloadedandVerified(UpdateType type, int fileType,
String version, File file)
String version, File file)
throws IOException {
_log.info("Got an update to post-process");
if (type != UpdateType.ROUTER_SIGNED_SU3 &&
@ -44,20 +48,6 @@ public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
_log.warn("Unsupported update type " + type);
return;
}
if (fileType != SU3File.TYPE_ZIP) {
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 ZipUpdateProcess(ctx, this::getVersion, this::getFile));
}
if (SystemVersion.isWindows()) {
if (fileType != SU3File.TYPE_EXE) {
@ -77,6 +67,21 @@ public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
ctx.addFinalShutdownTask(
new WinUpdateProcess(ctx, this::getVersion, this::getFile));
} else {
if (fileType == SU3File.TYPE_ZIP) {
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 ZipUpdateProcess(ctx, this::getVersion, this::getFile));
}
}
}
@ -96,12 +101,11 @@ public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
private File workDir() throws IOException {
if (this.ctx != null) {
File workDir =
new File(this.ctx.getConfigDir().getAbsolutePath(), "i2p_update_win");
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");
" exists but is a file, get it out of the way");
return null;
} else {
workDir.mkdirs();

View File

@ -14,7 +14,7 @@ class WinUpdateProcess implements Runnable {
private final Log _log;
WinUpdateProcess(RouterContext ctx, Supplier<String> versionSupplier,
Supplier<File> fileSupplier) {
Supplier<File> fileSupplier) {
this.ctx = ctx;
this.versionSupplier = versionSupplier;
this.fileSupplier = fileSupplier;
@ -23,12 +23,11 @@ class WinUpdateProcess implements Runnable {
private File workDir() throws IOException {
if (ctx != null) {
File workDir =
new File(ctx.getConfigDir().getAbsolutePath(), "i2p_update_win");
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");
" exists but is a file, get it out of the way");
return workDir;
} else {
workDir.mkdirs();
@ -47,43 +46,34 @@ class WinUpdateProcess implements Runnable {
File workingDir = workDir();
File logFile = new File(workingDir, "log-" + version + ".txt");
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());
Map<String, String> env = pb.environment();
env.put("OLD_I2P_VERSION", version);
env.remove("RESTART_I2P");
// 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());
Map<String, String> 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 {
Process p = pb.directory(workingDir)
.redirectErrorStream(true)
.redirectOutput(logFile)
.start();
exitCode = p.waitFor();
if (exitCode != 0)
_log.error("Update failed with exit code " + exitCode + " see " +
logFile.getAbsolutePath() + " for more details");
} catch (IOException ex) {
_log.error(
"Unable to run update program in background. Update will fail.",
ex);
} catch (InterruptedException ex) {
_log.error(
"Unable to run update program in background. Update will fail.",
ex);
}
} 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());
try {
Process p = pb.directory(workingDir)
.redirectErrorStream(true)
.redirectOutput(logFile)
.start();
exitCode = p.waitFor();
if (exitCode != 0)
_log.error("Update failed with exit code " + exitCode + " see " +
logFile.getAbsolutePath() + " for more details");
} catch (IOException ex) {
_log.error(
"Unable to run update program in background. Update will fail.", ex);
} catch (InterruptedException ex) {
_log.error(
"Unable to run update program in background. Update will fail.", ex);
}
}

View File

@ -0,0 +1,158 @@
package net.i2p.router;
import java.io.File;
import net.i2p.util.Log;
import net.i2p.router.RouterContext;
public class WindowsAppUtil extends WindowsServiceUtil {
private Log _log;
public void setLog(Log log) {
this._log = log;
}
private File checkPathEnvironmentVariable(String name) {
String path_override = System.getenv(name);
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(name + " is not a directory: " + path);
}
}
return null;
}
protected File selectHome() { // throws Exception {
File i2p = checkPathEnvironmentVariable("JPACKAGE_HOME");
if (i2p == null)
i2p = appImageHome();
return i2p;
}
/**
* get the path to the java home, for jpackage this is related to the
* executable itself, which is handy to know. It's a directory called runtime,
* relative to the root of the app-image on each platform:
*
* Windows - Root of appimage is 1 directory above directory named runtime
* ./runtime
*
* Linux - Root of appimage is 2 directories above directory named runtime
* ./lib/runtime
*
* Mac OSX - Unknown for now
*
* @return
*/
protected File javaHome() {
File jrehome = new File(System.getProperty("java.home"));
if (jrehome != null) {
if (jrehome.exists()) {
return jrehome;
}
}
return null;
}
/**
* get the path to the root of the app-image root by getting the path to
* java.home and the OS, and traversing up to the app-image root based on that
* information.
*
* @return the app-image root
*/
protected File appImageHome() {
File jreHome = javaHome();
if (jreHome != null) {
switch (osName()) {
case "windows":
return jreHome.getAbsoluteFile().getParentFile();
case "mac":
case "linux":
return jreHome.getAbsoluteFile().getParentFile().getParentFile();
}
}
return null;
}
/**
* get the path to the binary of the app-image root by getting the path to
* java.home and the OS, and traversing up to the app-image root based on that
* information, then getting the binary path on a per-platform basis. The path
* returned will be relative to the root.
*
* @return the app-image root + the path to the executable
*/
protected String appImageExe() {
File aih = appImageHome();
if (aih != null) {
// get the name of the aih directory itself, which will be the default
// name of the executable as well
String baseName = aih.getName();
switch (osName()) {
case "windows":
return baseName + ".exe";
case "mac":
case "linux":
return "./bin/" + baseName;
}
}
return null;
}
/**
* get the path to the default config of the app-image by getting the path to
* java.home and the OS, and traversing up to the app-image root based on that
* information, then appending the config directory to the end onn a
* per-platform basis
*
* @return the app-image root
*/
protected File appImageConfig() {
File aih = appImageHome();
if (aih == null) {
return null;
}
String osName = osName();
switch (osName) {
case "windows":
File winConfigDir = new File(aih, "config");
if (winConfigDir != null) {
if (winConfigDir.exists()) {
return winConfigDir;
}
}
case "mac":
case "linux":
File linConfigDir = new File(aih, "lib/config");
if (linConfigDir != null) {
if (linConfigDir.exists()) {
File cfg = new File(linConfigDir, "router.config");
if (cfg.canWrite())
return linConfigDir;
else {
String home = System.getenv("HOME");
if (home != null)
linConfigDir = new File(home,"i2p-config");
}
return linConfigDir;
}
}
}
return null;
}
protected String routerConfig() {
File appImageHomeDir = selectHome();
File routerConf = new File(appImageHomeDir, "router.config");
if (routerConf != null) {
if (routerConf.exists()) {
return routerConf.getAbsolutePath();
}
}
return null;
}
}

View File

@ -30,8 +30,10 @@ import javax.swing.JOptionPane;
*/
public class WindowsServiceUtil {
public WindowsServiceUtil() {}
public static String queryService(String serviceName) {
public WindowsServiceUtil() {
}
public String queryService(String serviceName) {
String result = "";
String line;
ProcessBuilder pb = new ProcessBuilder("sc", "query", serviceName);
@ -39,8 +41,7 @@ public class WindowsServiceUtil {
Process p = pb.start();
try {
p.waitFor(); // wait for process to finish then continue.
BufferedReader bri =
new BufferedReader(new InputStreamReader(p.getInputStream()));
BufferedReader bri = new BufferedReader(new InputStreamReader(p.getInputStream()));
while ((line = bri.readLine()) != null) {
result += line;
}
@ -54,7 +55,8 @@ public class WindowsServiceUtil {
}
return result;
}
public static String getStatePrefix(String qResult) {
public String getStatePrefix(String qResult) {
String statePrefix = "STATE : ";
// get the first occurrence of "STATE", then find the
// next occurrence of of ":" after that. Count the
@ -70,8 +72,9 @@ public class WindowsServiceUtil {
}
return statePrefix;
}
public static int getServiceStateInt(String serviceName) {
// String statePrefix = "STATE : ";
public int getServiceStateInt(String serviceName) {
// String statePrefix = "STATE : ";
String qResult = queryService(serviceName);
String statePrefix = getStatePrefix(qResult);
// check that the temp string contains the status prefix
@ -79,21 +82,21 @@ public class WindowsServiceUtil {
if (ix >= 0) {
// compare status number to one of the states
String stateStr = qResult.substring(ix + statePrefix.length(),
ix + statePrefix.length() + 1);
ix + statePrefix.length() + 1);
int state = Integer.parseInt(stateStr);
return state;
}
return -2;
}
public static boolean isInstalled(String serviceName) {
public boolean isInstalled(String serviceName) {
if (getServiceState(serviceName).equals("uninstalled")) {
return false;
}
return true;
}
public static boolean isStart(String serviceName) {
public boolean isStart(String serviceName) {
if (getServiceState(serviceName).equals("started")) {
return true;
}
@ -106,22 +109,19 @@ public class WindowsServiceUtil {
return false;
}
public static boolean promptServiceStartIfAvailable(String serviceName) {
public boolean promptServiceStartIfAvailable(String serviceName) {
if (osName() != "windows") {
return true;
}
if (isInstalled(serviceName)) {
if (!isStart(serviceName)) {
int a;
String message =
"It appears you have an existing I2P service installed.\n";
message +=
"However, it is not running yet. Please start it through `services.msc`.\n";
message +=
"If you click \"No\", the jpackage router will be launched instead.\n";
String message = "It appears you have an existing I2P service installed.\n";
message += "However, it is not running yet. Please start it through `services.msc`.\n";
message += "If you click \"No\", the jpackage router will be launched instead.\n";
a = JOptionPane.showConfirmDialog(null, message,
"I2P Service detected not running",
JOptionPane.YES_NO_OPTION);
"I2P Service detected not running",
JOptionPane.YES_NO_OPTION);
if (a == JOptionPane.NO_OPTION) {
// Do nothing here, this will continue on to launch a jpackaged router
return true;
@ -131,8 +131,7 @@ public class WindowsServiceUtil {
// user can start the service themselves. OR maybe we ask for
// elevation here? May need to refactor Elevator and Shell32X to
// achieve it though
ProcessBuilder pb =
new ProcessBuilder("C:\\Windows\\System32\\services.msc");
ProcessBuilder pb = new ProcessBuilder("C:\\Windows\\System32\\services.msc");
try {
Process p = pb.start();
int exitCode = p.waitFor();
@ -145,112 +144,38 @@ public class WindowsServiceUtil {
return false;
}
}
return isStart("i2p");
return isStart(serviceName);
}
return true;
}
return true;
}
public static String ServiceUpdaterString() {
return "http://tc73n4kivdroccekirco7rhgxdg5f3cjvbaapabupeyzrqwv5guq.b32.i2p/news.su3";
}
public static String ServiceBackupUpdaterString() {
return "http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news.su3";
}
public static String ServiceStaticUpdaterString() {
return "http://echelon.i2p/i2p/i2pupdate.sud,http://stats.i2p/i2p/i2pupdate.sud";
}
public static String getProgramFilesInstall() {
String programFiles = System.getenv("PROGRAMFILES");
if (programFiles != null) {
File programFilesI2P = new File(programFiles, "i2p/i2p.exe");
if (programFilesI2P.exists())
return programFilesI2P.getAbsolutePath();
}
String programFiles86 = System.getenv("PROGRAMFILES86");
if (programFiles86 != null) {
File programFiles86I2P = new File(programFiles86, "i2p/i2p.exe");
if (programFiles86I2P.exists())
return programFiles86I2P.getAbsolutePath();
}
return null;
}
public static boolean checkProgramFilesInstall() {
String programFiles = System.getenv("PROGRAMFILES");
if (programFiles != null) {
File programFilesI2P = new File(programFiles, "i2p/i2p.exe");
if (programFilesI2P.exists())
return true;
}
String programFiles86 = System.getenv("PROGRAMFILES86");
if (programFiles86 != null) {
File programFiles86I2P = new File(programFiles86, "i2p/i2p.exe");
if (programFiles86I2P.exists())
return true;
}
return false;
}
public static boolean promptUserInstallStartIfAvailable() {
if (osName() != "windows") {
return true;
}
if (checkProgramFilesInstall()) {
int a;
String message =
"It appears you have an existing, unbundled I2P rotuer installed.\n";
message +=
"However, it is not running yet. Please start it using the shortcut on the desktop.\n";
message +=
"If you click \"No\", the jpackage router will be launched instead.\n";
a = JOptionPane.showConfirmDialog(null, message,
"I2P Service detected not running",
JOptionPane.YES_NO_OPTION);
if (a == JOptionPane.NO_OPTION) {
// Do nothing here, this will continue on to launch a jpackaged router
return true;
} else {
try {
String pfi = getProgramFilesInstall();
if (pfi != null)
Runtime.getRuntime().exec(pfi);
} catch (IOException e) {
return false;
}
return true;
}
}
return true;
}
public static String getServiceState(String serviceName) {
public String getServiceState(String serviceName) {
String stateString = "uninstalled";
int state = getServiceStateInt(serviceName);
switch (state) {
case (1): // service stopped
stateString = "stopped";
break;
case (2): // service starting
stateString = "starting";
break;
case (3): // service stopping
stateString = "stopping";
break;
case (4): // service started
stateString = "started";
break;
case (5): // service resuming from pause
stateString = "resuming";
break;
case (6): // service pausing
stateString = "pausing";
break;
case (7): // service paused
stateString = "paused";
break;
case (1): // service stopped
stateString = "stopped";
break;
case (2): // service starting
stateString = "starting";
break;
case (3): // service stopping
stateString = "stopping";
break;
case (4): // service started
stateString = "started";
break;
case (5): // service resuming from pause
stateString = "resuming";
break;
case (6): // service pausing
stateString = "pausing";
break;
case (7): // service paused
stateString = "paused";
break;
}
return stateString;
}
@ -258,9 +183,9 @@ public class WindowsServiceUtil {
/**
* get the OS name(windows, mac, linux only)
*
* @return os name in lower-case, "windows" "mac" or "linux"
* @return os name in lower-case, "windows" "mac" or "linux"
*/
protected static String osName() {
protected String osName() {
String osName = System.getProperty("os.name").toLowerCase();
if (osName.contains("windows"))
return "windows";
@ -268,12 +193,14 @@ public class WindowsServiceUtil {
return "mac";
return "linux";
}
public static void main(String args[]) {
WindowsServiceUtil wsu = new WindowsServiceUtil();
// when querying the I2P router service installed by the IzPack installer
// this is the correct call.
String state = getServiceState("i2p");
int stateInt = getServiceStateInt("i2p");
String state = wsu.getServiceState("i2p");
int stateInt = wsu.getServiceStateInt("i2p");
System.out.println("i2p state: " + state + " code: " + stateInt);
promptServiceStartIfAvailable("i2p");
wsu.promptServiceStartIfAvailable("i2p");
}
}

View File

@ -20,7 +20,7 @@ public class ZipUpdateProcess implements Runnable {
private final Log _log;
ZipUpdateProcess(RouterContext ctx, Supplier<String> versionSupplier,
Supplier<File> fileSupplier) {
Supplier<File> fileSupplier) {
this.ctx = ctx;
this.versionSupplier = versionSupplier;
this.fileSupplier = fileSupplier;
@ -29,12 +29,11 @@ public class ZipUpdateProcess implements Runnable {
private File workDir() throws IOException {
if (ctx != null) {
File workDir =
new File(ctx.getConfigDir().getAbsolutePath(), "i2p_update_zip");
File workDir = new File(ctx.getConfigDir().getAbsolutePath(), "i2p_update_zip");
if (workDir.exists()) {
if (workDir.isFile())
throw new IOException(workDir +
" exists but is a file, get it out of the way");
" exists but is a file, get it out of the way");
return workDir;
} else {
workDir.mkdirs();

View File

@ -1,35 +0,0 @@
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

View File

@ -1,41 +0,0 @@
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-Easy-Install-Bundle-$(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-Easy-Install-Bundle-$(PROFILE_VERSION)-signed" -signer "$(SIGNER)" -version "$(PROFILE_VERSION)"
java -cp "$(HOME)/i2p/lib/*" net.i2p.crypto.SU3File sign -c ROUTER -f EXE I2P-Easy-Install-Bundle-$(PROFILE_VERSION)-signed.exe I2P-Easy-Install-Bundle-$(PROFILE_VERSION)-signed.su3 "$(HOME)/.i2p-plugin-keys/news-su3-keystore.ks" $(PROFILE_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:
@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\": \"$(PROFILE_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

View File

@ -1,7 +1,7 @@
# This now requires v3
UniCode true
!define APPNAME "I2PBrowser-Launcher"
!define APPNAME "i2peasy"
!define COMPANYNAME "I2P"
!define DESCRIPTION "This is a tool which contains an I2P router, a bundled JVM, and a tool for automatically configuring a browser to use with I2P."
!define I2P_MESSAGE "Please choose a directory."
@ -10,7 +10,6 @@ UniCode true
!define CONSOLE_URL "http://127.0.0.1:7657/home"
!include i2pbrowser-version.nsi
!include i2pbrowser-jpackage.nsi
!include FindProcess.nsh
#var INSTDIR
@ -18,11 +17,11 @@ UniCode true
SetOverwrite on
!define INSTDIR
!define I2PINSTEXE_USERMODE "$LOCALAPPDATA\i2peasy"
!define I2PINSTEXE_USERMODE "$LOCALAPPDATA\${APPNAME}"
!define RAM_NEEDED_FOR_64BIT 0x80000000
InstallDir "$PROGRAMFILES64\${COMPANYNAME}\${APPNAME}"
InstallDir $LOCALAPPDATA\${APPNAME}
# rtf or txt file - remember if it is txt, it must be in the DOS text format (\r\n)
LicenseData "licenses\LICENSE.txt"
@ -132,11 +131,6 @@ Function .onInit
# Admin installs have been migrated to user-mode installs.
# But I'm leaving it because I might need it again if I support service installs.
StrCpy $INSTDIR "${I2PINSTEXE_USERMODE}"
UserInfo::GetAccountType
pop $0
${If} $0 != "admin"
StrCpy $INSTDIR "${I2PINSTEXE_USERMODE}"
${EndIf}
!insertmacro MUI_LANGDLL_DISPLAY
#Call ShouldInstall64Bit
# look for user installs
@ -157,8 +151,8 @@ Function routerDetect
createDirectory "$INSTDIR\"
SetOutPath "$INSTDIR\"
File /a /r "I2P/config/certificates"
File /a /r "I2P/config/geoip"
File /a /r "I2P\config\certificates\"
File /a /r "I2P\config\geoip\"
FunctionEnd
Function installerFunction
@ -168,11 +162,6 @@ Function installerFunction
Sleep 500
${LoopWhile} $0 <> 0
${EndIf}
# delete the jpackaged file for safety. Remove this IMMEDIATELY after the next release.
# early-adopters and daily-build users may have to manually delete config files if they
# uninstall.
# RELATED: line 246
Delete "$INSTDIR\jpackaged"
# set the installation directory as the destination for the following actions
createDirectory $INSTDIR
@ -188,15 +177,17 @@ Function installerFunction
# Install the licenses
createDirectory "$INSTDIR\licenses"
SetOutPath "$INSTDIR\licenses"
File /a /r "licenses/*"
File /a /r "licenses\"
SetOutPath "$INSTDIR"
createDirectory "$SMPROGRAMS\${APPNAME}"
CreateShortCut "$SMPROGRAMS\${APPNAME}\Browse I2P.lnk" "$INSTDIR\I2P.exe" "" "$INSTDIR\ui2pbrowser_icon.ico"
CreateShortCut "$SMPROGRAMS\${APPNAME}\Browse I2P - Temporary Identity.lnk" "$INSTDIR\I2P.exe -private" "" "$INSTDIR\ui2pbrowser_icon.ico"
Delete "$SMPROGRAMS\${APPNAME}\Browse I2P - Temporary Identity.lnk"
CreateShortCut "$DESKTOP\Browse I2P.lnk" "$INSTDIR\I2P.exe" "" "$INSTDIR\ui2pbrowser_icon.ico"
CreateShortCut "$DESKTOP\Browse I2P - Temporary Identity.lnk" "$INSTDIR\I2P.exe -private" "" "$INSTDIR\ui2pbrowser_icon.ico"
Delete "$DESKTOP\Browse I2P - Temporary Identity.lnk"
CreateShortCut "$SMPROGRAMS\${APPNAME}\Uninstall I2P Easy-Install Bundle.lnk" "$INSTDIR\uninstall-i2pbrowser.exe" "" "$INSTDIR\ui2pbrowser_icon.ico"
SetOutPath "$INSTDIR"
@ -285,21 +276,9 @@ Function LaunchLink
${If} ${Silent}
ReadEnvStr $0 RESTART_I2P
${If} $0 != ""
UserInfo::GetAccountType
pop $0
${If} $0 == "admin"
ShellExecAsUser::ShellExecAsUser "open" "$DESKTOP\Browse I2P.lnk"
${Else}
ExecShell "" "$DESKTOP\Browse I2P.lnk"
${EndIf}
${EndIf}
${Else}
UserInfo::GetAccountType
pop $0
${If} $0 == "admin"
ShellExecAsUser::ShellExecAsUser "open" "$DESKTOP\Browse I2P.lnk"
${Else}
ExecShell "" "$DESKTOP\Browse I2P.lnk"
${EndIf}
${EndIf}
FunctionEnd

View File

@ -1 +0,0 @@
!define I2P_VERSION

View File

@ -1,3 +1,3 @@
!define VERSIONMAJOR 2
!define VERSIONMINOR 1
!define VERSIONMINOR 6
!define VERSIONBUILD 0

View File

@ -1,8 +1,10 @@
#!/bin/bash
TORSOCKS=$(which torsocks)
if [ -f "${TORSOCKS}" ]; then
. "${TORSOCKS}" on
if [ -z "$NO_TORSOCKS" ]; then
TORSOCKS=$(which torsocks)
if [ -f "${TORSOCKS}" ]; then
. "${TORSOCKS}" on
fi
fi
version="$(curl -s https://aus1.torproject.org/torbrowser/update_3/release/downloads.json | jq -r ".version")"
@ -18,10 +20,11 @@ if [ ! -f ./tor.keyring ]; then
fi
if [ ! -f "tor-browser-linux64-${version}_${locale}.tar.xz" ]; then
wget -cv "https://www.torproject.org/dist/torbrowser/${version}/tor-browser-linux64-${version}_${locale}.tar.xz"
wget -cv "https://www.torproject.org/dist/torbrowser/${version}/tor-browser-linux64-${version}_${locale}.tar.xz.asc"
wget -cv "https://www.torproject.org/dist/torbrowser/${version}/tor-browser-linux-x86_64-${version}.tar.xz"
https://dist.torproject.org/torbrowser/13.0.9/
wget -cv "https://www.torproject.org/dist/torbrowser/${version}/tor-browser-linux-x86_64-${version}.tar.xz.asc"
fi
gpgv --keyring ./tor.keyring "tor-browser-linux64-${version}_${locale}.tar.xz.asc" "tor-browser-linux64-${version}_${locale}.tar.xz"
gpgv --keyring ./tor.keyring "tor-browser-linux-x86_64-${version}.tar.xz.asc" "tor-browser-linux-x86_64-${version}.tar.xz"
tar xvJf "tor-browser-linux64-${version}_${locale}.tar.xz"
tar xvJf "tor-browser-linux-x86_64-${version}.tar.xz"

View File

@ -18,21 +18,11 @@ if [ ! -f ./tor.keyring ]; then
fi
if [ ! -f "tor-browser-linux64-${version}_${locale}.exe" ]; then
wget -cv "https://www.torproject.org/dist/torbrowser/${version}/torbrowser-install-win64-${version}_${locale}.exe"
wget -cv "https://www.torproject.org/dist/torbrowser/${version}/torbrowser-install-win64-${version}_${locale}.exe.asc"
wget -cv "https://dist.torproject.org/torbrowser/${version}/tor-browser-windows-x86_64-portable-${version}.exe"
wget -cv "https://dist.torproject.org/torbrowser/${version}/tor-browser-windows-x86_64-portable-${version}.exe.asc"
fi
gpgv --keyring ./tor.keyring "torbrowser-install-win64-${version}_${locale}.exe.asc" "torbrowser-install-win64-${version}_${locale}.exe"
gpgv --keyring ./tor.keyring "tor-browser-windows-x86_64-portable-${version}.exe.asc" "tor-browser-windows-x86_64-portable-${version}.exe"
#tar xvJf "torbrowser-install-win64-${version}_${locale}.exe"
#for n in `seq 1 2000`; do echo $n; dd ibs=256 if="torbrowser-install-win64-${version}_${locale}.exe" count=2 skip=$n | file - ; done 2>/dev/null |less
#zip -FF "torbrowser-install-win64-${version}_${locale}.exe" --out extracted.zip
WINE=$(which wine)
if [ -z "$WINE" ]; then
"./torbrowser-install-win64-${version}_${locale}.exe" /S #/D .
cp -vr "$HOME/Desktop/Tor Browser/" "Tor Browser"
else
export WINEPREFIX=$(pwd)/../tmp
$WINE "torbrowser-install-win64-${version}_${locale}.exe" /S #/D .
cp -vr "$WINEPREFIX/drive_c/users/idk/Desktop/Tor Browser/" "Tor Browser"
fi
7z x "tor-browser-windows-x86_64-portable-${version}.exe" -o"Tor Browser"
#7z --help

View File

@ -36,6 +36,7 @@ img {
left: 5%;
max-width: 60%;
display: inline;
padding-right: 2%;
}
.inline {
@ -74,8 +75,6 @@ iframe {
}
.container {
width: 36vw;
height: 64vh;
display: inline-block;
margin: 0;
padding: 0;