summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xREADME7
-rwxr-xr-xdebian/control2
-rwxr-xr-xvchat-client.sgml9
-rwxr-xr-xvchat-howto5
-rwxr-xr-xvchat-keygen6
-rwxr-xr-xvchat-protocol.c8
-rwxr-xr-xvchat-ssl.c18
7 files changed, 36 insertions, 19 deletions
diff --git a/README b/README
index 402826c..2a32f88 100755
--- a/README
+++ b/README
@@ -2,16 +2,15 @@ Hi!
2 2
3this is vchat-client, a GPLed (SSL) client for the vchat protocol. 3this is vchat-client, a GPLed (SSL) client for the vchat protocol.
4 4
5You can get the most recent version of vchat-client via CVS, e.g: 5You can get the most recent version of vchat-client via git, e.g:
6 6
7cvs -d:pserver:anoncvs@cvs.erdgeist.org:/home/cvsroot login 7git clone git://erdgeist.org/vchat-client
8cvs -z3 -d:pserver:anoncvs@cvs.erdgeist.org:/home/cvsroot co vchat-client
9 8
10(press return at password prompt) 9(press return at password prompt)
11 10
12no autoconf yet, sorry. required libs: 11no autoconf yet, sorry. required libs:
13 12
14openssl (0.9.6+ preferred) 13openssl (1.0.1g+ preferred)
15readline (4.2+ preferred) 14readline (4.2+ preferred)
16ncurses (5.2 preferred) 15ncurses (5.2 preferred)
17 16
diff --git a/debian/control b/debian/control
index d106fd5..3ba3fcd 100755
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: vchat-client
2Section: unknown 2Section: unknown
3Priority: optional 3Priority: optional
4Maintainer: Andreas Kotes <count@flatline.de> 4Maintainer: Andreas Kotes <count@flatline.de>
5Build-Depends: debhelper (>> 3.0.0), libreadline4-dev, libncurses-dev, libssl-dev, docbook-to-man 5Build-Depends: debhelper (>> 3.0.0), libreadline-dev, libncurses-dev, libssl-dev, docbook-to-man
6Standards-Version: 3.5.2 6Standards-Version: 3.5.2
7 7
8Package: vchat-client 8Package: vchat-client
diff --git a/vchat-client.sgml b/vchat-client.sgml
index ee0dc36..4b4f130 100755
--- a/vchat-client.sgml
+++ b/vchat-client.sgml
@@ -262,16 +262,15 @@ TAB nick completion
262<refsect1> 262<refsect1>
263<title>DEVEL</title> 263<title>DEVEL</title>
264 264
265<para>You can get the most recent version of vchat-client via CVS, e.g: 265<para>You can get the most recent version of vchat-client via git, e.g:
266<screen> 266<screen>
267<prompt>$ </prompt><userinput>cvs -d:pserver:anonymous@pulse.flatline.de:/home/cvsroot login</userinput> 267<prompt>$ </prompt><userinput>git clone git://erdgeist.org/vchat-client</userinput>
268<prompt>$ </prompt><userinput>cvs -z3 -d:pserver:anonymous@pulse.flatline.de:/home/cvsroot co vchat-client</userinput>
269</screen> 268</screen>
270</para> 269</para>
271 270
272<para>(press return at password prompt) no autoconf yet, sorry. required libs: 271<para>(press return at password prompt) no autoconf yet, sorry. required libs:
273<literallayout> 272<literallayout>
274 - openssl (0.9.6+ preferred) 273 - openssl (1.0.1g+ preferred)
275 - readline (4.2+ preferred) 274 - readline (4.2+ preferred)
276 - ncurses (5.2 preferred) 275 - ncurses (5.2 preferred)
277</literallayout> 276</literallayout>
@@ -337,7 +336,7 @@ the admins has to be logged in.</para>
337<refsect1> 336<refsect1>
338 337
339<title>SEE ALSO</title> 338<title>SEE ALSO</title>
340<para>gcc (1), cvs (1).</para> 339<para>gcc (1), git (1).</para>
341 340
342</refsect1> 341</refsect1>
343 342
diff --git a/vchat-howto b/vchat-howto
index 22c34b7..0ace213 100755
--- a/vchat-howto
+++ b/vchat-howto
@@ -4,13 +4,12 @@ Newbies Guide to vchat via 'Buntclient'
41. Get the Source, Luke 41. Get the Source, Luke
5----------------------- 5-----------------------
6 6
7Make sure, you got a shell and the tool called cvs. 7Make sure, you got a shell and the tool called git.
8cd to a directory the source shall reside in. 8cd to a directory the source shall reside in.
9 9
10Type: 10Type:
11 11
12$ cvs -d:pserver:anoncvs@cvs.erdgeist.org:/home/cvsroot login 12$ git clone git://erdgeist.org/vchat-client
13$ cvs -z3 -d:pserver:anoncvs@cvs.erdgeist.org:/home/cvsroot co vchat-client
14 13
15(press return at password prompt) 14(press return at password prompt)
16 15
diff --git a/vchat-keygen b/vchat-keygen
index fa92c60..91fcbba 100755
--- a/vchat-keygen
+++ b/vchat-keygen
@@ -29,7 +29,7 @@ if [ ! -e $KEYBASE.key ]; then
29 echo "vchat-keygen: generating RSA key $KEYBASE.key" 29 echo "vchat-keygen: generating RSA key $KEYBASE.key"
30 echo "vchat-keygen: please set passphrase for local security" 30 echo "vchat-keygen: please set passphrase for local security"
31 umask 0077 31 umask 0077
32 openssl genrsa -des3 -out $KEYBASE.key 2048 32 openssl genrsa -des3 -out $KEYBASE.key 4096
33else 33else
34 echo "vchat-keygen: private key $KEYBASE.key exists" 34 echo "vchat-keygen: private key $KEYBASE.key exists"
35fi 35fi
@@ -40,7 +40,7 @@ fi
40 echo "vchat-keygen: generating config-file for self-signing $KEYBASE.ca.keyconf" 40 echo "vchat-keygen: generating config-file for self-signing $KEYBASE.ca.keyconf"
41 cat >$KEYBASE.ca.keyconf <<EOT 41 cat >$KEYBASE.ca.keyconf <<EOT
42[ req ] 42[ req ]
43default_bits = 2048 43default_bits = 4096
44default_keyfile = user.key 44default_keyfile = user.key
45distinguished_name = req_distinguished_name 45distinguished_name = req_distinguished_name
46string_mask = nombstr 46string_mask = nombstr
@@ -57,7 +57,7 @@ EOT
57 fi 57 fi
58 echo "vchat-keygen: generating Certificate Signing Request $KEYBASE.csr" 58 echo "vchat-keygen: generating Certificate Signing Request $KEYBASE.csr"
59 echo "vchat-keygen: please enter your nickname at the 'Name []:' prompt" 59 echo "vchat-keygen: please enter your nickname at the 'Name []:' prompt"
60 openssl req -new -config $KEYBASE.ca.keyconf -key $KEYBASE.key -out $KEYBASE.csr 60 openssl req -new -sha1 -config $KEYBASE.ca.keyconf -key $KEYBASE.key -out $KEYBASE.csr
61 echo "vchat-keygen: send this ($KEYBASE.csr) Certificate Signing Request to 61 echo "vchat-keygen: send this ($KEYBASE.csr) Certificate Signing Request to
62 vchat@vchat.berlin.ccc.de to get it signed by the vchat-CA. You will 62 vchat@vchat.berlin.ccc.de to get it signed by the vchat-CA. You will
63 receive your signed Certificate shortly." 63 receive your signed Certificate shortly."
diff --git a/vchat-protocol.c b/vchat-protocol.c
index b50f511..e676b28 100755
--- a/vchat-protocol.c
+++ b/vchat-protocol.c
@@ -166,8 +166,11 @@ vcconnect (char *server, char *port)
166 } 166 }
167 167
168 /* upgrade our plain BIO to ssl */ 168 /* upgrade our plain BIO to ssl */
169 if( vc_connect_ssl( &server_conn, &vc_store ) ) 169 if( vc_connect_ssl( &server_conn, &vc_store ) ) {
170 BIO_free_all( server_conn ); 170 BIO_free_all( server_conn );
171 server_conn = NULL;
172 errno = EIO;
173 }
171 } 174 }
172 175
173 if( !server_conn ) { 176 if( !server_conn ) {
@@ -188,7 +191,8 @@ vcconnect (char *server, char *port)
188/* disconnect from server */ 191/* disconnect from server */
189void 192void
190vcdisconnect () { 193vcdisconnect () {
191 BIO_free_all( server_conn ); 194 if (server_conn)
195 BIO_free_all( server_conn );
192 serverfd = -1; 196 serverfd = -1;
193} 197}
194 198
diff --git a/vchat-ssl.c b/vchat-ssl.c
index 41b0278..64886ca 100755
--- a/vchat-ssl.c
+++ b/vchat-ssl.c
@@ -137,8 +137,24 @@ int vc_connect_ssl( BIO **conn, vc_x509store_t *vc_store )
137 BIO_push( ssl_conn, *conn ); 137 BIO_push( ssl_conn, *conn );
138 *conn = ssl_conn; 138 *conn = ssl_conn;
139 fflush(stdout); 139 fflush(stdout);
140 if( BIO_do_handshake( *conn ) > 0 ) 140 if( BIO_do_handshake( *conn ) > 0 ) {
141 /* Show information about cipher used */
142 const SSL *sslp = NULL;
143 const SSL_CIPHER * cipher = NULL;
144
145 /* Get cipher object */
146 BIO_get_ssl(ssl_conn, &sslp);
147 cipher = SSL_get_current_cipher(sslp);
148 if (cipher) {
149 char cipher_desc[TMPSTRSIZE];
150 snprintf(tmpstr, TMPSTRSIZE, "[SSL CIPHER] %s", SSL_CIPHER_description(cipher, cipher_desc, TMPSTRSIZE));
151 writecf(FS_SERV, tmpstr);
152 } else {
153 snprintf(tmpstr, TMPSTRSIZE, "[SSL ERROR] Cipher not known / SSL object can't be queried!");
154 writecf(FS_ERR, tmpstr);
155 }
141 return 0; 156 return 0;
157 }
142 } 158 }
143 159
144 snprintf(tmpstr, TMPSTRSIZE, "[SSL ERROR] %s", ERR_error_string (ERR_get_error (), NULL)); 160 snprintf(tmpstr, TMPSTRSIZE, "[SSL ERROR] %s", ERR_error_string (ERR_get_error (), NULL));