comparison src/protocols/yahoo/yahoo.c @ 10740:94cc67130789

[gaim-migrate @ 12342] More big changes, yay. I combined gaim_connection_new and gaim_connection_connect. Earlier today I realized that it's dumb to have a GaimConnection that isn't connected. I'm about to combine gaim_connection_disconnect and gaim_connection_destroy, as well. I added a "password" field to GaimConnection. It holds the password used to login a specific GaimConnection. Now, when "remember password" is false, account->password is NEVER set. When the user tries to sign on and Gaim prompts for the password, it goes directly into the GaimConnection. committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Sat, 26 Mar 2005 23:25:18 +0000
parents 55af3fa46329
children 1f51dd1a7f87
comparison
equal deleted inserted replaced
10739:42dbc4ba1325 10740:94cc67130789
918 static void yahoo_process_auth_old(GaimConnection *gc, const char *seed) 918 static void yahoo_process_auth_old(GaimConnection *gc, const char *seed)
919 { 919 {
920 struct yahoo_packet *pack; 920 struct yahoo_packet *pack;
921 GaimAccount *account = gaim_connection_get_account(gc); 921 GaimAccount *account = gaim_connection_get_account(gc);
922 const char *name = gaim_normalize(account, gaim_account_get_username(account)); 922 const char *name = gaim_normalize(account, gaim_account_get_username(account));
923 const char *pass = gaim_account_get_password(account); 923 const char *pass = gaim_connection_get_password(gc);
924 struct yahoo_data *yd = gc->proto_data; 924 struct yahoo_data *yd = gc->proto_data;
925 925
926 /* So, Yahoo has stopped supporting its older clients in India, and undoubtedly 926 /* So, Yahoo has stopped supporting its older clients in India, and undoubtedly
927 * will soon do so in the rest of the world. 927 * will soon do so in the rest of the world.
928 * 928 *
1035 static void yahoo_process_auth_new(GaimConnection *gc, const char *seed) 1035 static void yahoo_process_auth_new(GaimConnection *gc, const char *seed)
1036 { 1036 {
1037 struct yahoo_packet *pack = NULL; 1037 struct yahoo_packet *pack = NULL;
1038 GaimAccount *account = gaim_connection_get_account(gc); 1038 GaimAccount *account = gaim_connection_get_account(gc);
1039 const char *name = gaim_normalize(account, gaim_account_get_username(account)); 1039 const char *name = gaim_normalize(account, gaim_account_get_username(account));
1040 const char *pass = gaim_account_get_password(account); 1040 const char *pass = gaim_connection_get_password(gc);
1041 struct yahoo_data *yd = gc->proto_data; 1041 struct yahoo_data *yd = gc->proto_data;
1042 1042
1043 GaimCipher *md5_cipher; 1043 GaimCipher *md5_cipher;
1044 GaimCipherContext *md5_ctx; 1044 GaimCipherContext *md5_ctx;
1045 guint8 md5_digest[16]; 1045 guint8 md5_digest[16];
2170 { 2170 {
2171 GaimConnection *gc = (GaimConnection *)user_data; 2171 GaimConnection *gc = (GaimConnection *)user_data;
2172 GaimAccount *account = gaim_connection_get_account(gc); 2172 GaimAccount *account = gaim_connection_get_account(gc);
2173 struct yahoo_data *yd = gc->proto_data; 2173 struct yahoo_data *yd = gc->proto_data;
2174 const char *sn = gaim_account_get_username(account); 2174 const char *sn = gaim_account_get_username(account);
2175 const char *pass = gaim_account_get_password(account); 2175 const char *pass = gaim_connection_get_password(gc);
2176 GHashTable *hash = yahoo_login_page_hash(buf, len); 2176 GHashTable *hash = yahoo_login_page_hash(buf, len);
2177 GString *url = g_string_new("GET http://login.yahoo.com/config/login?login="); 2177 GString *url = g_string_new("GET http://login.yahoo.com/config/login?login=");
2178 char md5[33], *hashp = md5, *chal; 2178 char md5[33], *hashp = md5, *chal;
2179 int i; 2179 int i;
2180 GaimCipher *cipher; 2180 GaimCipher *cipher;