README_HR.md 13 KB

cjdns

English Русская версия Svenska Ελληνικά Deutsch 繁體中文 Español Français

Umrežavanje iznova

Cjdns je šifrirana IPv6 mreža koja koristi public-key kriptografiju za dodjelu adresa i DHT za usmjeravanje. To omogućuje gotovo nikakvu mrežnu konfiguraciju i sprječava mnoge sigurnosne i skalabilne probleme koje muče trenutne mreže.

Build Status napojnica za sljedeću promjenu

Iskustva

23:26 <@jercos> well, cjdns is now officially more reliable than the open
                internet for getting to my cheaper VPSes :|

12:52 < mariner> so i don't know if it's been done before, and i assume it's
                 obvious, but I think it's neat. Currently on hype from an
                 airplane

00:36 < tester> man sites take so long to load on i2p
00:36 < tester> i value speed over anonymity any day

<DuoNoxSol> it's notably more reliable than the normal internet
<DuoNoxSol> even though it really really shouldn't be
<DuoNoxSol> seeing as the connections are largely over the normal internet

Zajednica

Dokumentacija

Napredna konfiguracija:

Hvala Vam za vaše vrijeme i interes,

Cjdns programeri.


Kako instalirati cjdns

Ove instrukcije su namijenjene za distribucije bazirane na Debian Linux-u i macOS-u. Trebale bi biti dovoljno informativne za korištenje na ostalim distribucijama, ali ne očekujte da će raditi od prve.

0. Install dependencies

On both platforms, installing Node.js, although preferable, is not strictly necessary. If Node.js is unavailable or an unacceptable version, it will be downloaded and installed in the source tree.

Distribucija bazirana na Debianu:

sudo apt-get install nodejs git build-essential python2.7

Distribucija bazirana na Fedori 22+:

sudo dnf install install nodejs git
sudo dnf install @development-tools

Distribucija bazirana na RHELu (dodaje EPEL repozitorij):

sudo yum localinstall https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
sudo yum install install nodejs git
sudo yum install @development-tools

macOS:

Instalacija putem Homebrewa:

brew install cjdns

Instalacija putem MacPortsa:

sudo port install cjdns

OpenBSD:

pkg_add git node gcc gmake bash

Odaberite verziju gcc-4.8.1p2 ili noviju.

FreeBSD:

pkg install gmake node

Arch:

Možete instalirati cjdns sljedećom naredbom;

pacman -S cjdns

If you need to build from source, everything you need can be installed like this

pacman -S nodejs git base-devel

Alternatively, you may like to install via AUR from the package, cjdns-git. Nakon instalacije konfiguracijska datoteka će se nalaziti u /etc/cjdroute.conf. Za pokrenuti servis cjdns.service, pokrenite sljedeću naredbu:

    systemctl start cjdns

Za zaustavljanje:

   systemctl stop cjdns

Gentoo:

cjdns is not yet in the main Gentoo repository, so you will have to use an overlay. The easiest way is to use Layman but you can do it by hand, too.

Layman:

Prvo treba te instalirati layman:

  emerge layman

If layman is installed correctly, you can add the overlay

  layman -f
  layman -a weuxel

For future update of the overlay use

  layman -S

Now you can install cjdns

  emerge cjdns
By hand:

You will have to clone the overlay repository

   cd /opt
   git clone https://github.com/Weuxel/portage-weuxel.git

Now tell portage to use this repo

   cd /etc/portage/repos.conf/

Create a file portage-weuxel.conf containing

   [weuxel]
   location = /opt/portage-weuxel
   masters = gentoo
   auto-sync = yes

Now sync

   emerge --sync

And install cjdns

emerge cjdns

Automatic crash detection and restart

Copy the the openrc init script from contrib/openrc to /etc/init.d/ and modify the CONFFILE and command parameter to your needs. Then start cjdns by issuing

/etc/init.d/cjdns start

Configure the init system to autostart cjdns

rc-update add cjdns default

Copy the service_restart script contrib/gentoo/service_restart.sh to any convenient directory on your system and modify the eMail address. If you do not wish to be notified, comment out the whole line. Now add a crontab entry like this

# Restart crashed Services

  • * * * * root /path/to/script/service_restart.sh

Solus:

Dependencies:

  sudo eopkg install nodejs git build-essential system.devel python gcc binutils kernal-headers xorg-server-devel

Then Follow the steps below:

Sorry for so many steps. A package is being worked on currently

1. Preuzmite cjdns sa GitHuba

Clone the repository from GitHub and change to the source directory:

git clone https://github.com/cjdelisle/cjdns.git cjdns
cd cjdns

2. Build

./do

Potražite Build completed successfully, type ./cjdroute to begin setup., zatim nastavite:


Setup

Run cjdroute without options for HELP:

./cjdroute

0. Provjerite imate li potrebne stvari

LANG=C cat /dev/net/tun

Ako kaže: cat: /dev/net/tun: File descriptor in bad state, sve je u redu!

Ako kaže: cat: /dev/net/tun: No such file or directory, stvorite ga putem:

sudo mkdir -p /dev/net &&
sudo mknod /dev/net/tun c 10 200 &&
sudo chmod 0666 /dev/net/tun

Zatim opet pokrenite cat /dev/net/tun.

Ako kaže: cat: /dev/net/tun: Permission denied vjerojatno koristite VPS baziran na OpenVZ virtualizacijskoj platformi. Pitajte vašeg pružatelja usluga da vam omogući TUN/TAP - ovo je standardni protokol tako da bi trebali znati što trebate. Ako ste na macOSu, ne morate se brinuti u vezi ove greške.

1. Stvorite novu konfiguracijsku datoteku

./cjdroute --genconf >> cjdroute.conf

Zaštitite Vašu konfiguraciju! A lost conf file means you lost your password and connections and anyone who connected to you will no longer be able to connect. A compromised conf file means that other people can impersonate you on the network.

To set generate a conf file with permissions set so that only your user can read it and write to it:

(umask 077 && ./cjdroute --genconf > cjdroute.conf)

2. Pronađite prijatelja

Kako biste ušli u postojeću mrežu (npr. Hyperboria), morate se spojiti s nekime tko je već unutar te mreže. To je tako zbog nekoliko razloga:

  1. It helps prevent abuse because bad people will be less likely to abuse a system after they were, in an act of human kindness, given access to that system.
  2. This is not intended to overlay The Old Internet, it is intended to replace it. Each connection will in due time be replaced by a wire, a fiber optic cable, or a wireless network connection.
  3. In any case of a disagreement, there will be a "chain of friends" linking the people involved so there will already be a basis for coming to a resolution.

To find a friend, get out there and join our community. Also, have a look at the Hyperboria Map to find peers near you.

3. Spojite vaš node sa nodeom prijatelja

Za pokretanje izlazne konekcije

U Vašoj conf datoteci vidjeti ćete:

// Nodes to connect to.
"connectTo":
{
    // Add connection credentials here to join the network
    // Ask somebody who is already connected.
}

A conf file with multiple friend-nodes, setup OUTbound, should look like:

// Nodes to connect to.
"connectTo":
{
    //friend_1 (IPv4: 0.1.2.3; IPv6 fcaa:5bac:66e4:713:cb00:e446:c317:fc39)
    "0.1.2.3:45678":
    {
        "password": "thisIsNotARealConnection_1",
        "publicKey": "thisIsJustForAnExampleDoNotUseThisInYourConfFile_1.k"
    }

    //friend_2 (IPv4: 5.1.2.3; IPv6 fcbb:5bac:66e4:713:cb00:e446:c317:fc39)
    "5.1.2.3:5678":
    {
        "password": "thisIsNotARealConnection_2",
        "publicKey": "thisIsJustForAnExampleDoNotUseThisInYourConfFile_2.k"
    }
}

You can add as many connections as you want to the connectTo attribute, following JSON syntax.

To allow your friend to initiate the connection INbound

U Vašoj conf datoteci vidjeti ćete:

"authorizedPasswords":
[
    // A unique string which is known to the client and server.
    {"password": "password001", "login": "default-login"}

    // More passwords should look like this.
    // {"password": "password002", "login": "my-second-peer"}
    // {"password": "password003", "login": "my-third-peer}
    // {"password": "password004", "login": "my-fourth-peer"}
    ...

    // "your.external.ip.goes.here:45678":{"login": "default-login", "password": "password001","publicKey":thisisauniqueKEY_001.k"}

],

A conf file with multiple friend-nodes, setup INbound, should look like:

"authorizedPasswords":
[
    // A unique string which is known to the client and server.
    {"password": "thisisauniquestring_001", "user": "k.alexander"}

    // More passwords should look like this.
    //William Jevons (IPv4: 0.1.2.3; IPv6 fcaa:5bac:66e4:713:cb00:e446:c317:fc39)
    {"password": "thisisauniquestring_002", "user": "William Jevons"}
    //Marilyn Patel (IPv4: 5.1.2.3; IPv6 fcbb:5bac:66e4:713:cb00:e446:c317:fc39)
    {"password": "thisisauniquestring_003", "user": "Marilyn Patel"}
    // {"password": "thisisauniquestring_004"}
    ...

    // "your.external.ip.goes.here:45678":{"password": "thisisauniquestring_001","publicKey":thisisauniqueKEY_001.k"}
],

Morate dati friend_3 (who is making the INbound connection) sljedeće 4 stvari:

  1. Vašu vanjsku IPv4 adresu
  2. Port iz konfiguracijske datoteke:

            `// Bind to this port.
            "bind": "0.0.0.0:yourportnumberishere",`
    
  3. Their unique password that you uncommented or created: "password": "thisisauniquestring_002"

  4. Vaš javni ključ: "publicKey": "thisisauniqueKEY_001.k"

Please note that you and your friend can initiate a connection either outbound (from YOU --> FRIEND) or inbound (from FRIEND --> YOU) but traffic flows both ways once the connection is established.

See doc/configure.md for more details on configuration, including how to peer with other cjdns nodes over ethernet and wifi.

4. Zaštitite Vaš sustav - check for listening services

Nakon što se Vaš node pokrene, postajete IPv6 host. Vaš operativni sustav će automatski konfigurirati mrežne servise kako bi koristili novu adresu. Ako ovo nije Vaš cilj, trebali bi ste provjeriti da ne pružate više servisa nego što mislite. ;)

Pogledajte doc/network-services.md za instrukcije.

5. Pokrenite ga!

sudo ./cjdroute < cjdroute.conf

Ako želite da se logovi zapisuju u datoteku:

sudo ./cjdroute < cjdroute.conf > cjdroute.log

Za zaustavljanje cjdns-a:

sudo killall cjdroute

Ako imate problema koristite killall cjdroute. Koristite pgrep cjdroute ili top kako bi ste provjerili radi li cjdns.

Note: ovo pokreće cjdns kao putem korisnika tako da može konfigurirati Vaš sustav bez potrebnih dozvola. Za pokretanje cjdns-a putem običnog korisnika, pogledajte doc/non-root-user.md.

6. Dođite na IRC

Dobrodošli u mrežu! Sada ste mrežni administrator. Kao mrežni administrator odgovorni ste za stvari poput kvara opreme. Budite na IRC-u kako bi vas ljudi mogli kontaktirati.

Administratorsko sučelje

Kada je cjdnroute pokrenut, administratorsko sučelje biti će dostupna na udp://localhost:11234 (ovo se može promijeniti u cjdroute.conf konfiguracijskoj datoteci). Pogledajte doc/admin-api.md za više informacija o administratorskom sučelju. U contrib/ se nalazi nekoliko alata s kojima može komunicirati.

Možete pristupiti administratorskom API-ju putem: