diff options
-rw-r--r-- | INSTALL.md | 23 | ||||
-rw-r--r-- | README.md | 11 | ||||
-rw-r--r-- | start_guide.md | 24 | ||||
-rw-r--r-- | testing/Lossless_UDP_testclient.c | 2 | ||||
-rw-r--r-- | testing/Lossless_UDP_testserver.c | 2 | ||||
-rw-r--r-- | testing/nTox.c | 23 | ||||
-rw-r--r-- | testing/toxic/prompt.c | 2 |
7 files changed, 63 insertions, 24 deletions
@@ -1,5 +1,17 @@ | |||
1 | #Install Instructions | ||
2 | |||
3 | - [Installation](#installation) | ||
4 | - [Linux](#linux) | ||
5 | - [OS X](#osx) | ||
6 | - [Homebrew](#homebrew) | ||
7 | - [Non-Homebrew](#non-homebrew) | ||
8 | - [Windows](#windows) | ||
9 | - [Usage](#usage) | ||
10 | |||
11 | <a name="installation" /> | ||
1 | ##Installation | 12 | ##Installation |
2 | 13 | ||
14 | <a name="linux" /> | ||
3 | ###Linux: | 15 | ###Linux: |
4 | 16 | ||
5 | Build dependencies: | 17 | Build dependencies: |
@@ -40,8 +52,10 @@ Or you could just build everything that is supported on your platform by running | |||
40 | make | 52 | make |
41 | ``` | 53 | ``` |
42 | 54 | ||
43 | ###OSX: | 55 | <a name="osx" /> |
56 | ###OS X: | ||
44 | 57 | ||
58 | <a name="homebrew" /> | ||
45 | ####Homebrew: | 59 | ####Homebrew: |
46 | ``` | 60 | ``` |
47 | brew install libtool automake autoconf libconfig libsodium | 61 | brew install libtool automake autoconf libconfig libsodium |
@@ -50,6 +64,7 @@ make | |||
50 | sudo make install | 64 | sudo make install |
51 | ``` | 65 | ``` |
52 | 66 | ||
67 | <a name="non-homebrew" /> | ||
53 | ####Non-homebrew: | 68 | ####Non-homebrew: |
54 | 69 | ||
55 | Much the same as Linux, remember to install the latest XCode and the developer tools (Preferences -> Downloads -> Command Line Tools). | 70 | Much the same as Linux, remember to install the latest XCode and the developer tools (Preferences -> Downloads -> Command Line Tools). |
@@ -69,6 +84,7 @@ Another thing you may want to install is the latest gcc, this caused me a few pr | |||
69 | no longer includes gcc and instead uses LLVM-GCC, a nice install guide can be found at | 84 | no longer includes gcc and instead uses LLVM-GCC, a nice install guide can be found at |
70 | http://caiustheory.com/install-gcc-421-apple-build-56663-with-xcode-42 | 85 | http://caiustheory.com/install-gcc-421-apple-build-56663-with-xcode-42 |
71 | 86 | ||
87 | <a name="windows" /> | ||
72 | ###Windows: | 88 | ###Windows: |
73 | 89 | ||
74 | You should install: | 90 | You should install: |
@@ -100,3 +116,8 @@ Or you could just build everything that is supported on your platform by running | |||
100 | ```bash | 116 | ```bash |
101 | mingw32-make | 117 | mingw32-make |
102 | ``` | 118 | ``` |
119 | |||
120 | <a name="usage" /> | ||
121 | ## Usage | ||
122 | |||
123 | - [Start Guide](start_guide.md) | ||
@@ -28,7 +28,7 @@ Keep everything really simple. | |||
28 | 28 | ||
29 | ## Roadmap: | 29 | ## Roadmap: |
30 | - [x] Get our DHT working perfectly. (Done, needs large scale testing though) | 30 | - [x] Get our DHT working perfectly. (Done, needs large scale testing though) |
31 | - [x] Reliable connection (See Lossless UDP protocol) to other peers according to client ID. (Done, see DHT_sendfiletest.c for an example) | 31 | - [x] Reliable connection (See Lossless UDP protocol) to other peers according to client ID. (Done, see `DHT_sendfiletest.c` for an example) |
32 | - [x] Encryption. (Done) | 32 | - [x] Encryption. (Done) |
33 | - [ ] Get a simple text only IM client working perfectly. (This is where we are) | 33 | - [ ] Get a simple text only IM client working perfectly. (This is where we are) |
34 | - [ ] Streaming media | 34 | - [ ] Streaming media |
@@ -45,7 +45,8 @@ configure for the normal user or suffer from being way too centralized. | |||
45 | 45 | ||
46 | ### Documentation: | 46 | ### Documentation: |
47 | 47 | ||
48 | [DHT Protocol](https://github.com/irungentoo/ProjectTox-Core/wiki/DHT)<br /> | 48 | - [Installation](/INSTALL.md) |
49 | [Lossless UDP Protocol](https://github.com/irungentoo/ProjectTox-Core/wiki/Lossless-UDP)<br /> | 49 | - [DHT Protocol](https://github.com/irungentoo/ProjectTox-Core/wiki/DHT)<br /> |
50 | [Crypto](https://github.com/irungentoo/ProjectTox-Core/wiki/Crypto)<br /> | 50 | - [Lossless UDP Protocol](https://github.com/irungentoo/ProjectTox-Core/wiki/Lossless-UDP)<br /> |
51 | [Ideas](https://github.com/irungentoo/ProjectTox-Core/wiki/Ideas) | 51 | - [Crypto](https://github.com/irungentoo/ProjectTox-Core/wiki/Crypto)<br /> |
52 | - [Ideas](https://github.com/irungentoo/ProjectTox-Core/wiki/Ideas) | ||
diff --git a/start_guide.md b/start_guide.md index b4f4310d..31d7ca8e 100644 --- a/start_guide.md +++ b/start_guide.md | |||
@@ -1,5 +1,5 @@ | |||
1 | # Using Tox | 1 | # Using Tox |
2 | 1. Build Tox | 2 | 1. [Build Tox](/INSTALL.md) |
3 | 2. Fix errors | 3 | 2. Fix errors |
4 | 3. Consult IRC for help | 4 | 3. Consult IRC for help |
5 | 4. Go on debugging journy for devs | 5 | 4. Go on debugging journy for devs |
@@ -13,25 +13,25 @@ Tox. Here's a user-friendly attempt at it. | |||
13 | 1. Connect to the network! | 13 | 1. Connect to the network! |
14 | + You need to connect to a bootstrapping server, to give you a public key. | 14 | + You need to connect to a bootstrapping server, to give you a public key. |
15 | + Where can I find a public server? Right here, as of now: | 15 | + Where can I find a public server? Right here, as of now: |
16 | (the help message from running nTox with no args will help) | 16 | (the help message from running `nTox` with no args will help) |
17 | + 198.46.136.167 33445 728925473812C7AAC482BE7250BCCAD0B8CB9F737BF3D42ABD34459C1768F854 | 17 | + `198.46.136.167 33445 728925473812C7AAC482BE7250BCCAD0B8CB9F737BF3D42ABD34459C1768F854` |
18 | + 192.81.133.111 33445 8CD5A9BF0A6CE358BA36F7A653F99FA6B258FF756E490F52C1F98CC420F78858 | 18 | + `192.81.133.111 33445 8CD5A9BF0A6CE358BA36F7A653F99FA6B258FF756E490F52C1F98CC420F78858` |
19 | + 66.175.223.88 33445 AC4112C975240CAD260BB2FCD134266521FAAF0A5D159C5FD3201196191E4F5D | 19 | + `66.175.223.88 33445 AC4112C975240CAD260BB2FCD134266521FAAF0A5D159C5FD3201196191E4F5D` |
20 | + 192.184.81.118 33445 5CD7EB176C19A2FD840406CD56177BB8E75587BB366F7BB3004B19E3EDC04143 | 20 | + `192.184.81.118 33445 5CD7EB176C19A2FD840406CD56177BB8E75587BB366F7BB3004B19E3EDC04143` |
21 | 2. Find a friend! | 21 | 2. Find a friend! |
22 | + Now that you're on the network, you need a friend. To get one of those, | 22 | + Now that you're on the network, you need a friend. To get one of those, |
23 | you need to to send or receive a request. What's a request, you ask? | 23 | you need to to send or receive a request. What's a request, you ask? |
24 | It's like a friend request, but we use really scary and cryptic numbers | 24 | It's like a friend request, but we use really scary and cryptic numbers |
25 | instead of names. When nTox starts, it shows your _your_ long, scary number, | 25 | instead of names. When `nTox` starts, it shows your _your_ long, scary number, |
26 | called your *public key*. Give that to people, and they can add you as | 26 | called your *public key*. Give that to people, and they can add you as |
27 | as "friend". Or, you can add someone else, with the */f* command, if you like. | 27 | as "friend". Or, you can add someone else, with the `/f` command, if you like. |
28 | 3. Chat it up! | 28 | 3. Chat it up! |
29 | + Now use the */m* command to send a message to someone. Wow, you're chatting! | 29 | + Now use the `/m` command to send a message to someone. Wow, you're chatting! |
30 | 4. But something broke! | 30 | 4. But something broke! |
31 | + Yeah, pre-alpha-alpha software tends to do that. We're working on it. | 31 | + Yeah, pre-alpha-alpha software tends to do that. We're working on it. |
32 | + Please report all crashes to either the github page, or #tox-dev on freenode. | 32 | + Please report all crashes to either the [github](/) page, or `#tox-dev` on freenode. |
33 | 5. Nothing broke, but what does */f* mean? | 33 | 5. Nothing broke, but what does `/f` mean? |
34 | + nTox parses text as a command if the first character is a forward-slash ('/'). | 34 | + `nTox` parses text as a command if the first character is a forward-slash (`/`). |
35 | You can check all commands in commands.md. | 35 | You can check all commands in commands.md. |
36 | 6. Use and support Tox! | 36 | 6. Use and support Tox! |
37 | + Code for us, debug for us, document for us, translate for us, even just talk about us! | 37 | + Code for us, debug for us, document for us, translate for us, even just talk about us! |
diff --git a/testing/Lossless_UDP_testclient.c b/testing/Lossless_UDP_testclient.c index b96756ab..7093afec 100644 --- a/testing/Lossless_UDP_testclient.c +++ b/testing/Lossless_UDP_testclient.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * | 4 | * |
5 | * Best used in combination with Lossless_UDP_testserver | 5 | * Best used in combination with Lossless_UDP_testserver |
6 | * | 6 | * |
7 | * Compile with: gcc -O2 -Wall -o testclient ../core/network.c ../core/Lossless_UDP.c Lossless_UDP_testclient.c | 7 | * Compile with: gcc -O2 -Wall -lsodium -o testclient ../core/network.c ../core/Lossless_UDP.c Lossless_UDP_testclient.c |
8 | * | 8 | * |
9 | * Command line arguments are the ip and port to connect and send the file to. | 9 | * Command line arguments are the ip and port to connect and send the file to. |
10 | * EX: ./testclient 127.0.0.1 33445 filename.txt | 10 | * EX: ./testclient 127.0.0.1 33445 filename.txt |
diff --git a/testing/Lossless_UDP_testserver.c b/testing/Lossless_UDP_testserver.c index 29b0ade5..84a64b38 100644 --- a/testing/Lossless_UDP_testserver.c +++ b/testing/Lossless_UDP_testserver.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * | 4 | * |
5 | * Best used in combination with Lossless_UDP_testclient | 5 | * Best used in combination with Lossless_UDP_testclient |
6 | * | 6 | * |
7 | * Compile with: gcc -O2 -Wall -o testserver ../core/network.c ../core/Lossless_UDP.c Lossless_UDP_testserver.c | 7 | * Compile with: gcc -O2 -Wall -lsodium -o testserver ../core/network.c ../core/Lossless_UDP.c Lossless_UDP_testserver.c |
8 | * | 8 | * |
9 | * Command line argument is the name of the file to save what we recieve to. | 9 | * Command line argument is the name of the file to save what we recieve to. |
10 | * EX: ./testserver filename1.txt | 10 | * EX: ./testserver filename1.txt |
diff --git a/testing/nTox.c b/testing/nTox.c index 7c84871f..17f4b0e7 100644 --- a/testing/nTox.c +++ b/testing/nTox.c | |||
@@ -97,17 +97,34 @@ void line_eval(char lines[HISTORY][STRING_LENGTH], char *line) | |||
97 | { | 97 | { |
98 | if (line[0] == '/') { | 98 | if (line[0] == '/') { |
99 | char inpt_command = line[1]; | 99 | char inpt_command = line[1]; |
100 | char prompt[STRING_LENGTH + 2] = "> "; | 100 | char prompt[STRING_LENGTH+2] = "> "; |
101 | int prompt_offset = 3; | ||
101 | strcat(prompt, line); | 102 | strcat(prompt, line); |
102 | new_lines(prompt); | 103 | new_lines(prompt); |
103 | if (inpt_command == 'f') { // add friend command: /f ID | 104 | if (inpt_command == 'f') { // add friend command: /f ID |
104 | int i; | 105 | int i; |
105 | char temp_id[128]; | 106 | char temp_id[128]; |
106 | for (i = 0; i < 128; i++) | 107 | for (i = 0; i < 128; i++) |
107 | temp_id[i] = line[i+3]; | 108 | temp_id[i] = line[i+prompt_offset]; |
108 | int num = m_addfriend(hex_string_to_bin(temp_id), (uint8_t*)"Install Gentoo", sizeof("Install Gentoo")); | 109 | int num = m_addfriend(hex_string_to_bin(temp_id), (uint8_t*)"Install Gentoo", sizeof("Install Gentoo")); |
109 | char numstring[100]; | 110 | char numstring[100]; |
110 | sprintf(numstring, "[i] added friend %d", num); | 111 | switch (num) { |
112 | case -1: | ||
113 | sprintf(numstring, "[i] Incorrect key length"); | ||
114 | break; | ||
115 | case -2: | ||
116 | sprintf(numstring, "[i] That appears to be your own key"); | ||
117 | break; | ||
118 | case -3: | ||
119 | sprintf(numstring, "[i] Friend request already sent"); | ||
120 | break; | ||
121 | case -4: | ||
122 | sprintf(numstring, "[i] Could not add friend"); | ||
123 | break; | ||
124 | default: | ||
125 | sprintf(numstring, "[i] Added friend %d", num); | ||
126 | break; | ||
127 | } | ||
111 | new_lines(numstring); | 128 | new_lines(numstring); |
112 | do_refresh(); | 129 | do_refresh(); |
113 | } | 130 | } |
diff --git a/testing/toxic/prompt.c b/testing/toxic/prompt.c index f1b6e689..b09b3d8d 100644 --- a/testing/toxic/prompt.c +++ b/testing/toxic/prompt.c | |||
@@ -148,7 +148,7 @@ static void execute(ToxWindow* self, char* cmd) { | |||
148 | msg++; | 148 | msg++; |
149 | 149 | ||
150 | m_set_userstatus((uint8_t*) msg, strlen(msg)+1); | 150 | m_set_userstatus((uint8_t*) msg, strlen(msg)+1); |
151 | wprintw(self->window, "Status set to: %s.\n", msg); | 151 | wprintw(self->window, "Status set to: %s\n", msg); |
152 | } | 152 | } |
153 | else if(!strncmp(cmd, "nick ", strlen("nick "))) { | 153 | else if(!strncmp(cmd, "nick ", strlen("nick "))) { |
154 | char* nick; | 154 | char* nick; |