|
|
@ -103,37 +103,38 @@ void OtrlConfInterface::generateNewPrivKey( TQString accountId, TQString protoco
|
|
|
|
popup->close();
|
|
|
|
popup->close();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
TQValueList<TQString[5]> OtrlConfInterface::readAllFingerprints(){
|
|
|
|
TQValueList<TQStringList> OtrlConfInterface::readAllFingerprints(){
|
|
|
|
ConnContext *context;
|
|
|
|
ConnContext *context;
|
|
|
|
Fingerprint *fingerprint;
|
|
|
|
Fingerprint *fingerprint;
|
|
|
|
TQString entry[5];
|
|
|
|
TQStringList entry;
|
|
|
|
char hash[45];
|
|
|
|
char hash[45];
|
|
|
|
TQValueList<TQString[5]> list;
|
|
|
|
TQValueList<TQStringList> list;
|
|
|
|
|
|
|
|
|
|
|
|
for( context = userstate->context_root; context != NULL; context = context->next ){
|
|
|
|
for( context = userstate->context_root; context != NULL; context = context->next ){
|
|
|
|
fingerprint = context->fingerprint_root.next;
|
|
|
|
fingerprint = context->fingerprint_root.next;
|
|
|
|
while( fingerprint ){
|
|
|
|
while( fingerprint ){
|
|
|
|
entry[0] = context->username;
|
|
|
|
entry.clear();
|
|
|
|
|
|
|
|
entry << context->username;
|
|
|
|
|
|
|
|
|
|
|
|
if( ( context->msgstate == OTRL_MSGSTATE_ENCRYPTED ) && ( context->active_fingerprint != fingerprint ) ){
|
|
|
|
if( ( context->msgstate == OTRL_MSGSTATE_ENCRYPTED ) && ( context->active_fingerprint != fingerprint ) ){
|
|
|
|
entry[1] = i18n("Unused");
|
|
|
|
entry << i18n("Unused");
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
if (context && context->msgstate == OTRL_MSGSTATE_ENCRYPTED) {
|
|
|
|
if (context && context->msgstate == OTRL_MSGSTATE_ENCRYPTED) {
|
|
|
|
if (context->active_fingerprint->trust && context->active_fingerprint->trust[0] != 0) {
|
|
|
|
if (context->active_fingerprint->trust && context->active_fingerprint->trust[0] != 0) {
|
|
|
|
entry[1] = i18n("Private");
|
|
|
|
entry << i18n("Private");
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
entry[1] = i18n("Unverified");
|
|
|
|
entry << i18n("Unverified");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else if (context && context->msgstate == OTRL_MSGSTATE_FINISHED) {
|
|
|
|
} else if (context && context->msgstate == OTRL_MSGSTATE_FINISHED) {
|
|
|
|
entry[1] = i18n("Finished");
|
|
|
|
entry << i18n("Finished");
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
entry[1] = i18n("Not Private");
|
|
|
|
entry << i18n("Not Private");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
entry[2] = ( fingerprint->trust && fingerprint->trust[0] ) ? i18n("Yes") : i18n("No") ;
|
|
|
|
entry << ((fingerprint->trust && fingerprint->trust[0]) ? i18n("Yes") : i18n("No"));
|
|
|
|
otrl_privkey_hash_to_human( hash, fingerprint->fingerprint );
|
|
|
|
otrl_privkey_hash_to_human( hash, fingerprint->fingerprint );
|
|
|
|
entry[3] = hash;
|
|
|
|
entry << hash;
|
|
|
|
entry[4] = context->protocol;
|
|
|
|
entry << context->protocol;
|
|
|
|
list << entry;
|
|
|
|
list << entry;
|
|
|
|
fingerprint = fingerprint->next;
|
|
|
|
fingerprint = fingerprint->next;
|
|
|
|
}
|
|
|
|
}
|
|
|
|