gPass

gPass Commit Details

Date:2017-04-17 20:39:53 (2 years 2 months ago)
Author:Grégory Soutadé
Branch:master
Commit:416a4d9581a90adbedb68bd924193921cb0cde80
Parents: 6dfcab813dbf409a2618a6342a57bf3191c9cfa2
Message:Use old passwords decryption for protocols < 4

Changes:
Mchrome_addon/lib/main.js (3 diffs)

File differences

chrome_addon/lib/main.js
175175
176176
177177
178
178
179179
180180
181181
......
216216
217217
218218
219
220
221
222
223
224
225
219
226220
227221
228222
......
230224
231225
232226
227
228
229
230
231
232
233233
234234
235235
case 3:
// Version 3 : nothing special to do
case 4:
// Version 3 : nothing special to do
// Version 4 : nothing special to do
break;
}
}
if (ciphered_password != "")
{
debug("Ciphered password : " + ciphered_password);
if (matched_key < logins.length)
{
clear_password = await decrypt_cbc(mkey, global_iv, hex2a(ciphered_password));
clear_password = clear_password.replace(/\0*$/, "");
clear_password = clear_password.substr(3, clear_password.length);
}
else
if (matched_key >= logins.logins || server_protocol_version < 4)
// Crypto v1
{
clear_password = await decrypt_ecb(mkey, hex2a(ciphered_password));
clear_password = clear_password.replace(/\0*$/, "");
clear_password = clear_password.substr(0, clear_password.length-3);
}
else
{
clear_password = await decrypt_cbc(mkey, global_iv, hex2a(ciphered_password));
clear_password = clear_password.replace(/\0*$/, "");
clear_password = clear_password.substr(3, clear_password.length);
}
debug("Clear password " + clear_password);
field.value = clear_password;
// Remove gPass event listener and submit again with clear password

Archive Download the corresponding diff file