Mercurial > pidgin
comparison libpurple/sslconn.c @ 18958:db67f6b39b72
- Hack up sslconn to use a single-use verifier
author | William Ehlhardt <williamehlhardt@gmail.com> |
---|---|
date | Wed, 27 Jun 2007 00:22:40 +0000 |
parents | 014e0cd9e471 |
children | 88be01d503fb 1677ead39ee3 |
comparison
equal
deleted
inserted
replaced
18957:9205841eed06 | 18958:db67f6b39b72 |
---|---|
116 gsc->port = port; | 116 gsc->port = port; |
117 gsc->connect_cb_data = data; | 117 gsc->connect_cb_data = data; |
118 gsc->connect_cb = func; | 118 gsc->connect_cb = func; |
119 gsc->error_cb = error_func; | 119 gsc->error_cb = error_func; |
120 | 120 |
121 /* TODO: remove the following line, as the verifier should be | |
122 specified Somewhere Else */ | |
123 gsc->verifier = purple_certificate_find_verifier("x509","singleuse"); | |
124 | |
121 gsc->connect_data = purple_proxy_connect(NULL, account, host, port, purple_ssl_connect_cb, gsc); | 125 gsc->connect_data = purple_proxy_connect(NULL, account, host, port, purple_ssl_connect_cb, gsc); |
122 | 126 |
123 if (gsc->connect_data == NULL) | 127 if (gsc->connect_data == NULL) |
124 { | 128 { |
125 g_free(gsc->host); | 129 g_free(gsc->host); |
188 gsc->error_cb = error_func; | 192 gsc->error_cb = error_func; |
189 gsc->fd = fd; | 193 gsc->fd = fd; |
190 if(host) | 194 if(host) |
191 gsc->host = g_strdup(host); | 195 gsc->host = g_strdup(host); |
192 | 196 |
197 /* TODO: remove the following line, as the verifier should be | |
198 specified Somewhere Else */ | |
199 gsc->verifier = purple_certificate_find_verifier("x509","singleuse"); | |
200 | |
193 ops = purple_ssl_get_ops(); | 201 ops = purple_ssl_get_ops(); |
194 ops->connectfunc(gsc); | 202 ops->connectfunc(gsc); |
195 | 203 |
196 return (PurpleSslConnection *)gsc; | 204 return (PurpleSslConnection *)gsc; |
197 } | 205 } |