Commit 7a31d8ca authored by JC Brand's avatar JC Brand

User can now end an encrypted session.

parent 6ac24c3b
...@@ -326,10 +326,8 @@ ...@@ -326,10 +326,8 @@
break; break;
case otr.OTR.CONST.STATUS_END_OTR: case otr.OTR.CONST.STATUS_END_OTR:
if (this.otr.msgstate === otr.OTR.CONST.MSGSTATE_FINISHED) { if (this.otr.msgstate === otr.OTR.CONST.MSGSTATE_FINISHED) {
// XXX: inform the user that his correspondent has closed his end
// of the private connection and the user should do the same
this.set('otr_status', FINISHED); this.set('otr_status', FINISHED);
} else if (this.otr.msgstate === otr.OTR.CONST.MSGSTATE_FINISHED) { } else if (this.otr.msgstate === otr.OTR.CONST.MSGSTATE_PLAINTEXT) {
this.set('otr_status', UNENCRYPTED); this.set('otr_status', UNENCRYPTED);
} }
break; break;
...@@ -779,7 +777,7 @@ ...@@ -779,7 +777,7 @@
}, },
endOTR: function (ev) { endOTR: function (ev) {
alert('to be done'); this.model.otr.endOtr();
}, },
authOTR: function (ev) { authOTR: function (ev) {
...@@ -854,9 +852,9 @@ ...@@ -854,9 +852,9 @@
if (data.otr_status == UNENCRYPTED) { if (data.otr_status == UNENCRYPTED) {
msgs.push(__("Your messages are not encrypted anymore")); msgs.push(__("Your messages are not encrypted anymore"));
} else if (data.otr_status == UNVERIFIED){ } else if (data.otr_status == UNVERIFIED){
msgs.push(__("Your messages are encrypted but your buddy's identity has not been verified.")); msgs.push(__("Your messages are now encrypted but your buddy's identity has not been verified."));
} else if (data.otr_status == VERIFIED){ } else if (data.otr_status == VERIFIED){
msgs.push(__("Your messages are encrypted and your buddy's identify verified.")); msgs.push(__("Your buddy's identify has been verified."));
} else if (data.otr_status == FINISHED){ } else if (data.otr_status == FINISHED){
msgs.push(__("Your buddy has ended encryption on their end, you should do the same.")); msgs.push(__("Your buddy has ended encryption on their end, you should do the same."));
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment