Commit e871c965 authored by Tails developers's avatar Tails developers
Browse files

Merge branch 'feature/i2p-0.8.8' into devel

parents 7957681d cc2b70e7
......@@ -151,6 +151,18 @@ Package: xul-ext-torbutton
Pin: release o=Debian,a=unstable
Pin-Priority: 999
Package: service-wrapper
Pin: release o=Debian,a=experimental
Pin-Priority: 999
Package: libservice-wrapper-java
Pin: release o=Debian,a=experimental
Pin-Priority: 999
Package: libservice-wrapper-jni
Pin: release o=Debian,a=experimental
Pin-Priority: 999
Explanation: weirdness in chroot_apt install-binary
Package: *
Pin: release o=chroot_local-packages
......
#!/bin/sh
# This must be set in order for the i2p init script to work
sed -ie 's/^RUN_DAEMON=.*$/RUN_DAEMON="true"/' /etc/default/i2p
#!/bin/sh
# i2p should not start per default. At some point we might want this script to
# start during init if so selected in the boot options, but ATM users have to
# start the script manually.
update-rc.d -f i2p remove
......@@ -22,3 +22,9 @@ update-rc.d -f kexec remove
# we use kexec on halt too => enable kexec-load initscript on runlevel 0 as well
update-rc.d -f kexec-load remove
update-rc.d kexec-load stop 18 0 6 .
# i2p should not start per default. At some point we want some script to start
# i2p during init if so selected in tails-greeter, but ATM users have to start
# the i2p script manually.
update-rc.d -f i2p remove
......@@ -39,7 +39,7 @@
[0:0] -A OUTPUT -m owner --uid-owner debian-tor -j ACCEPT
# i2p is allowed to do anything it wants to.
[0:0] -A OUTPUT -m owner --uid-owner i2p-daemon -j ACCEPT
[0:0] -A OUTPUT -m owner --uid-owner i2psvc -j ACCEPT
# Everything else is dropped.
[0:0] -A OUTPUT -j REJECT --reject-with icmp-port-unreachable
......@@ -63,7 +63,7 @@ COMMIT
[0:0] -A OUTPUT -m owner --uid-owner debian-tor -j RETURN
# i2p is allowed to do anything it wants to.
[0:0] -A OUTPUT -m owner --uid-owner i2p-daemon -j RETURN
[0:0] -A OUTPUT -m owner --uid-owner i2psvc -j RETURN
# The htp user is allowed to connect to services listening on the https port...
[0:0] -A OUTPUT -m owner --uid-owner htp -p TCP --dport https -j RETURN
......
......@@ -40,7 +40,7 @@ sub get_router_port {
# TODO: more perlish way to do below?
# TODO: use netstat -p, check that a child of i2psvc runs the router console
sub router_status {
return !system("netstat -nl -A inet,inet6 | grep -q -e \"\\(\\(127\\.0\\.0\\.1\\)\\|\\(::1\\)\\):" . get_router_port() . "\"");
return !system("netstat -nl -A inet,inet6 | grep -qe \"\\(127\\.0\\.0\\.1\\|::1\\):" . get_router_port() . "\"");
}
sub open_router_console {
......@@ -66,10 +66,34 @@ my $notification = $notify->create(summary => $summary,
body => $body,
timeout => 0);
start_i2psvc();
$notification->show();
my $htp_success_file = '/var/lib/live/htp-success';
my $htp_wait = 0;
# There was a "fix" in i2p 0.8.8 for handling clock jumps and skews which seems
# to be broken -- a jump during i2p bootstrap leads to i2p starting in a non-
# working state, as does starting i2p when the clock is off too much. Hence, for
# simplicity, we make i2p dependent on HTP succeeding. The real fix will be when
# i2p gets its act together and handles these problems correctly.
until (-e $htp_success_file) {
if ($htp_wait > 60) {
$notification->close();
$summary = gettext("I2P failed to start");
$body = gettext("Make sure that you have a working Internet " .
"connection, then try to start I2P again.");
$notification = $notify->create(summary => $summary,
body => $body,
timeout => 60000);
$notification->show();
exit 1;
}
sleep(1);
$htp_wait++;
}
start_i2psvc();
my $t = 0;
my $timeout = 180;
while ($t < $timeout && !router_status()) {
......@@ -84,10 +108,10 @@ if (router_status()) {
exit 0;
} else {
stop_i2psvc();
$summary = gettext("I2P failed to start");
$body = gettext("Something went wrong when I2P was starting. Look in the following file for more information:") . "\n\t/tmp/wrapper.log" . "\n\t/var/lib/i2p/.i2p/logs/log-router-*.txt";
$body = gettext("Something went wrong when I2P was starting. Look in " .
"the logs in the following directory for " .
"more information:") . "\n\t/var/log/i2p/";
$notification = $notify->create(summary => $summary,
body => $body,
timeout => 60000);
......
......@@ -2,7 +2,7 @@
Categories=Network;
Comment=Anonymous overlay network
Exec=/usr/local/bin/tails-start-i2p
Icon=/usr/lib/i2p/eepsite/docroot/favicon.ico
Icon=/usr/share/i2p/eepsite/docroot/favicon.ico
Name=i2p
GenericName=Anonymous overlay network
Terminal=false
......
experimental.chroot
\ No newline at end of file
deb http://ftp.us.debian.org/debian/ experimental main
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment