Using Anonymous I2P Network on FreeBSD

Using Anonymous I2P Network on FreeBSD


I2P is the twin brother of the Tor network, but its creators often use the "opposite" method to solve the same engineering problem. For better anonymity, users can choose longer chains and higher traffic delays, since each I2P node is both a client and a server. I2P is encrypted from everyone on the I2P network, so site owners don't know who is visiting them, and clients don't know who they are actually targeting to get internet service content.

I2P is also often referred to as the Invisible Internet Project, its scalable and self-organizing network distributes packets between layers of anonymous networks that can run a number of applications while maintaining a high level of security and anonymity.

This article tries to discuss the installation and configuration of I2P on a FreeBSD machine. In this article the specifications used are as follows.

 

System Specifications

  • Processor: AMD Phenom(tm) II X4 955 Processor (K8-class CPU)
  • OS: FreeBSD 13.2 Stable
  • IP Server: 192.168.9.3
  • Hostname: router2
  • Versi I2P: i2p-0.9.48

    Using Anonymous I2P Network on FreeBSD   

 

On FreeBSD I2P can be installed in two ways, namely via FreeBSD Ports and PKG packages. We tried to implement both of these methods:  

root@router2:~ # cd /usr/ports/java/openjdk8
root@router2:/usr/ports/java/openjdk8 # make install clean

root@router2:~ # cd /usr/ports/security/i2p
root@router2:/usr/ports/security/i2p # make install clean
root@router2:~ # pkg install openjdk8
root@router2:~ # pkg install i2p

 

After the I2P installation is complete, create an I2P user and group. The I2P user and group will be located in the /home/i2p folder.  

root@router2:~ # adduser
Username: i2p
Full name: i2p router
Uid (Leave empty for default): enter
Login group [i2p]: enter
Login group is i2p. Invite i2p into other groups? []: enter
Login class [default]: enter
Shell (sh csh tcsh bash rbash git-shell nologin) [sh]: enter
Home directory [/home/i2p]: enter
Home directory permissions (Leave empty for default): enter
Use password-based authentication? [yes]: no enter
Lock out the account after creation? [no]: enter
Username   : i2p
Password   : <disabled>
Full Name  : i2p router
Uid        : 1002
Class      :
Groups     : i2p
Home       : /home/i2p
Home Mode  :
Shell      : /bin/sh
Locked     : no
OK? (yes/no): yes enter
adduser: INFO: Successfully added (i2p) to the user database.
Add another user? (yes/no): no enter
Goodbye!
root@router2:~ #

  Now that we have an I2P user/group, next create a startup in the rc.conf file, and put the following script in that file.

root@router2:~ # ee /etc/rc.confi2p_enable="YES"
i2p_user="i2p"

 

Open the /usr/local/etc/rc.d folder, find the i2p file, once you find it, open it. Delete the command="/usr/local/sbin/i2prouter" script and replace it with the command="/usr/home/i2p/i2p/runplain.sh" script.

Next, with the putty program, open the /usr/local/sbin folder. Don't forget to use the su i2p syntax, because if you don't use su i2p, the i2p program will be installed in root. You need to remember that the i2p program will not run in root, the i2p program can only run in the i2p user and group, so the i2p syntax is you enter the i2p user and group. Ending with exit you will leave the i2p user and group.

 

root@router2:~ # su i2p# cd /usr/local/sbin
# i2prouter install # exit

  The next step is to edit the runplain.sh file in the /usr/home/i2p/i2p folder. Delete or put a "#" at the beginning of the script and add the script I2PTEMP="/usr/home/i2p/i2p". The following is an example of the contents of the runplain.sh script file.

#!/bin/sh

# This runs the router by itself, WITHOUT the wrapper.
# This means the router will not restart if it crashes.
# Also, you will be using the default memory size, which is
# probably not enough for i2p, unless you set it below.
# You should really use the i2prouter script instead.
#

# Paths
# Note that (percent)INSTALL_PATH and (percent)SYSTEM_java_io_tmpdir
# should have been replaced by the izpack installer.
# If you did not run the installer, replace them with the appropriate path.
I2P="${HOME}/i2p"
#2PTEMP="%SYSTEM_java_io_tmpdir"
I2PTEMP="${HOME}/i2p"

Run I2P

root@router2:~ # service i2p restart

Or

root@router2:~ # reboot

 

After the I2P program is restarted or the server is rebooted, all I2P settings will be moved to the hidden folder /usr/home/i2p/.i2p. Try to notice the dot in front of i2p, it means the folder is hidden.

Now open the hidden folder /usr/home/i2p/.i2p. In this article, I will give the I2P console address the same as the FreeBSD Server IP address, which is 192.168.9.3. In order for the I2P browser console to open with the IP 192.168.9.3:7657, edit the following file:



In the clients.config.bak file in the script clientApp.0.args=7657 ::1,127.0.0.1 ./webapps/ and clientApp.4.args=http://127.0.0.1:7657/ replace with.

clientApp.0.args=7657 ::1,192.168.9.3 ./webapps/clientApp.4.args=http://192.168.9.3:7657/

Next, open the /usr/home/i2p/.i2p/clients.config.d folder, edit the file 00-net.i2p.router.web.RouterConsoleRunner-clients.config.

clientApp.0.args=7657 ::1,192.168.9.3 ./webapps/

You also edit the 04-net.i2p.apps.systray.UrlLauncher-clients.config file.

clientApp.0.args=http://192.168.9.3:7657/

  Once we have configured everything, restart the server computer.

root@router2:~ # reboot

 

Perform I2P Testing

After the reboot process is complete, and the computer returns to normal display, you can remote with Putty. Open the Yandex, Firefox or Chrome web browser. We just open Yandex to perform TEST, if the I2P router configuration menu opens, it means you have successfully installed the I2P program on the FreeBSD server.

Open the Google Chrome web browser, in the address bar menu "type Server IP http://192.168.9.3:7657", see the results on your monitor screen.

If the display looks like the image above, it means you have successfully installed the I2P program on the FreeBSD server. It's hard, isn't it, to install I2P, at the beginning of the installation I had difficulty, but finally I managed to install I2P. It is indeed easier to install TOR than I2P, but if you follow the steps explained above, you will definitely succeed in installing I2P.

 

How do you rate this article?

6


BSD Blockchain
BSD Blockchain

https://unixwinbsd.site


Linux BSD Blockchain
Linux BSD Blockchain

Opensource Blog (FreeBSD, Linux, OpenBSD) For Blockchain Network

Publish0x

Send a $0.01 microtip in crypto to the author, and earn yourself as you read!

20% to author / 80% to me.
We pay the tips from our rewards pool.