Mercurial > pidgin.yaz
comparison src/protocols/oscar/oscar.c @ 4952:b7dfce780963
[gaim-migrate @ 5286]
AOL has started requesting hashes again. This means they'll *probably* start
blocking again soon. The hash server we put up last time isn't working right
because we claim to be a different version of AIM now, so I hard-coded the values
in oscar.c and we'll have to keep updating that until we get it fixed. Stable Gaim
and TOC are unaffected. You should really update this so that OSCAR will work.
committer: Tailor Script <tailor@pidgin.im>
author | Sean Egan <seanegan@gmail.com> |
---|---|
date | Tue, 01 Apr 2003 20:47:50 +0000 |
parents | 8896e0894112 |
children | 6ae40a9c5514 |
comparison
equal
deleted
inserted
replaced
4951:207f1e546849 | 4952:b7dfce780963 |
---|---|
65 #define UC_NORMAL 0x10 | 65 #define UC_NORMAL 0x10 |
66 #define UC_AB 0x20 | 66 #define UC_AB 0x20 |
67 #define UC_WIRELESS 0x40 | 67 #define UC_WIRELESS 0x40 |
68 | 68 |
69 #define AIMHASHDATA "http://gaim.sourceforge.net/aim_data.php3" | 69 #define AIMHASHDATA "http://gaim.sourceforge.net/aim_data.php3" |
70 | |
71 const char oscarhashkey[] = {0x41, 0x4F, 0x4C, 0x20, 0x49, 0x6e, 0x73, 0x74, 0x61, | |
72 0x6e, 0x74, 0x20, 0x4d, 0x65, 0x73, 0x73, 0x65, 0x6e, | |
73 0x67, 0x65, 0x72, 0x00}; | |
74 const char oscarhashdata[] = {0x59, 0x6f, 0x75, 0x20, 0x68, 0x61, 0x76, 0x65, 0x20, | |
75 0x62, 0x65, 0x65, 0x6e, 0x20, 0x64, 0x69, 0x73, 0x63, | |
76 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x65, 0x64, 0x20, | |
77 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20, | |
78 0x41, 0x4F, 0x4C, 0x20, 0x49, 0x6e, 0x73, 0x74, 0x61, | |
79 0x6e, 0x74, 0x20, 0x4d, 0x65, 0x73, 0x73, 0x65, 0x6e, | |
80 0x67, 0x65, 0x72, 0x20, 0x53, 0x65, 0x72, 0x76, 0x69, | |
81 0x63, 0x65, 0x20, 0x28, 0x53, 0x4d, 0x29, 0x20, 0x66, | |
82 0x6f, 0x72, 0x20, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, | |
83 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, 0x20, 0x41, | |
84 0x4F, 0x4C, 0x20, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, | |
85 0x6b, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x75, 0x6e, | |
86 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x65, | |
87 0x64, 0x20, 0x73, 0x6f, 0x66, 0x74, 0x77, 0x61, 0x72, | |
88 0x65, 0x2e, 0x20, 0x20, 0x59, 0x6f, 0x75, 0x20, 0x63, | |
89 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, | |
90 0x61, 0x64, 0x20, 0x61, 0x20, 0x46, 0x52, 0x45, 0x45, | |
91 0x20, 0x66, 0x75, 0x6c, 0x6c, 0x79, 0x2d, 0x66, | |
92 0x65, 0x61, 0x74, 0x75, 0x72, 0x65, 0x64, 0x2c, 0x20, | |
93 0x61, 0x6e, 0x64, 0x20, 0x61, 0x75, 0x74, 0x68, 0x6f, | |
94 0x72, 0x69, 0x7a, 0x65, 0x64, 0x20, 0x63, 0x6c, 0x69, | |
95 0x65, 0x6e, 0x74, 0x2c, 0x20, 0x68, 0x65, 0x72, 0x65, 0x20, 0x3c, | |
96 0x61, 0x20, 0x68, 0x72, 0x65, 0x66, 0x3d, 0x22, 0x68, | |
97 0x74, 0x74, 0x70, 0x3a, 0x2f, 0x2f, 0x67, 0x61, 0x69, | |
98 0x6d, 0x2e, 0x73, 0x66, 0x2e, 0x6e, 0x65, 0x74, 0x2f, | |
99 0x66, 0x6f, 0x6f, 0x6c, 0x2e, 0x70, 0x68, 0x70, 0x22, | |
100 0x3e, 0x68, 0x74, 0x74, 0x70, 0x3a, 0x2f, 0x2f, 0x77, | |
101 0x77, 0x77, 0x2e, 0x61, 0x6f, 0x6c, 0x2e, 0x63, 0x6f, | |
102 0x6d, 0x2f, 0x61, 0x69, 0x6d, 0x2f, 0x64, 0x6f, 0x77, | |
103 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x32, 0x2e, 0x68, 0x74, | |
104 0x6d, 0x6c, 0x3c, 0x2f, 0x61, 0x3e, 0x20, 0x2e, 0x00}; | |
105 static gboolean damn_you_again(struct gaim_connection *gc); | |
70 | 106 |
71 static struct prpl *my_protocol = NULL; | 107 static struct prpl *my_protocol = NULL; |
72 | 108 |
73 /* For win32 compatability */ | 109 /* For win32 compatability */ |
74 G_MODULE_IMPORT GSList *connections; | 110 G_MODULE_IMPORT GSList *connections; |
556 } | 592 } |
557 | 593 |
558 aim_conn_completeconnect(sess, conn); | 594 aim_conn_completeconnect(sess, conn); |
559 gc->inpa = gaim_input_add(conn->fd, GAIM_INPUT_READ, oscar_callback, conn); | 595 gc->inpa = gaim_input_add(conn->fd, GAIM_INPUT_READ, oscar_callback, conn); |
560 debug_printf("Password sent, waiting for response\n"); | 596 debug_printf("Password sent, waiting for response\n"); |
597 g_timeout_add(20000, (GSourceFunc)damn_you_again, gc); | |
561 } | 598 } |
562 | 599 |
563 static void oscar_login(struct gaim_account *account) { | 600 static void oscar_login(struct gaim_account *account) { |
564 aim_session_t *sess; | 601 aim_session_t *sess; |
565 aim_conn_t *conn; | 602 aim_conn_t *conn; |
1211 debug_printf("\n"); | 1248 debug_printf("\n"); |
1212 gaim_input_remove(pos->inpa); | 1249 gaim_input_remove(pos->inpa); |
1213 close(pos->fd); | 1250 close(pos->fd); |
1214 aim_sendmemblock(od->sess, pos->conn, 0, 16, m, AIM_SENDMEMBLOCK_FLAG_ISHASH); | 1251 aim_sendmemblock(od->sess, pos->conn, 0, 16, m, AIM_SENDMEMBLOCK_FLAG_ISHASH); |
1215 g_free(pos); | 1252 g_free(pos); |
1253 } | |
1254 | |
1255 static gboolean damn_you_again(struct gaim_connection *gc) | |
1256 { | |
1257 /* The current hash is #defined above. We'll want to fix the hash server */ | |
1258 hash_func(oscarhashkey, oscarhashdata); | |
1259 return FALSE; | |
1216 } | 1260 } |
1217 | 1261 |
1218 static void straight_to_hell(gpointer data, gint source, GaimInputCondition cond) { | 1262 static void straight_to_hell(gpointer data, gint source, GaimInputCondition cond) { |
1219 struct pieceofcrap *pos = data; | 1263 struct pieceofcrap *pos = data; |
1220 char buf[BUF_LONG]; | 1264 char buf[BUF_LONG]; |