Tkabber plugins

Check-in [cdee71ca04]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Display more appropriate error messages in case of received OTR request but without any OTR key configured. Updated Russian and Ukrainian translations.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: cdee71ca042bfa431ed2307497591c5b138a71d2
User & Date: sgolovan 2015-12-27 13:51:39
Context
2016-01-02
13:04
Adjusted priority for the icon drawing procedure. check-in: 1b27e8c663 user: sgolovan tags: trunk
2015-12-27
13:51
Display more appropriate error messages in case of received OTR request but without any OTR key configured. Updated Russian and Ukrainian translations. check-in: cdee71ca04 user: sgolovan tags: trunk
13:48
Don't switch to plaintext message state on an OTR error message retrieving. Display a bit more meaningful error messages to a user in case of receiving OTR request with nismatched protocol version. Do not resend pending message if the peer has changed her OTR key between sessions. check-in: 6c3223e438 user: sgolovan tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ChangeLog.









1
2
3
4
5
6
7








2015-12-22  Sergei Golovan  <sgolovan@nes.ru>

	* custom-urls/custom-urls.tcl: Added custom URL for the Tkabber Fossil
	  repository artifacts, like [3cd34577a3]. Modified the custom URL
	  procedure to allow more flexible URL definitions. In particular,
	  regexps with more than one capture group are permitted.

>
>
>
>
>
>
>
>







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
2015-12-27  Sergei Golovan  <sgolovan@nes.ru>

	* otr/otr.tcl: Display more appropriate error messages in case of
	  received OTR request but without any OTR key configured.

	* otr/msgs/ru.msg, otr/msgs/uk.msg: Updated Russian and Ukrainian
	  translations.

2015-12-22  Sergei Golovan  <sgolovan@nes.ru>

	* custom-urls/custom-urls.tcl: Added custom URL for the Tkabber Fossil
	  repository artifacts, like [3cd34577a3]. Modified the custom URL
	  procedure to allow more flexible URL definitions. In particular,
	  regexps with more than one capture group are permitted.

Changes to otr/msgs/ru.msg.

19
20
21
22
23
24
25










26
27
28
29
30
31
32
::msgcat::mcset ru "Set authenticated" "Отметить как аутентифицированного"
::msgcat::mcset ru "Unmark for deletion" "Снять отметку для удаления"
::msgcat::mcset ru "Unset authenticated" "Отметить как не аутентифицированного"
::msgcat::mcset ru "Yes" "Да"
::msgcat::mcset ru "Your JID: " "Ваш JID:"

# ./otr.tcl










::msgcat::mcset ru "Advertise your support of OTR using the whitespace tag." \
        "Показывать поддержку OTR, используя метку из пробельных символов."
::msgcat::mcset ru "Allow Tkabber to use Off-the-Record protocol (version 2 or\
        3)." "Разрешить Tkabber'у использовать протокол OTR (версию 2 или 3)."
::msgcat::mcset ru "Allow encryption" "Разрешить шифрование"
::msgcat::mcset ru "Attach whitespace tag" \
        "Прикреплять метку из пробельных символов"







>
>
>
>
>
>
>
>
>
>







19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
::msgcat::mcset ru "Set authenticated" "Отметить как аутентифицированного"
::msgcat::mcset ru "Unmark for deletion" "Снять отметку для удаления"
::msgcat::mcset ru "Unset authenticated" "Отметить как не аутентифицированного"
::msgcat::mcset ru "Yes" "Да"
::msgcat::mcset ru "Your JID: " "Ваш JID:"

# ./otr.tcl
::msgcat::mcset ru "%s has requested an Off-the-Record private conversation,\
        but you can't maintain it because you don't have your OTR private key\
        configured." "%s предложил вам воспользоваться протоколом OTR для\
        безопасного разговора, но вы не можете его поддержать, потому что\
        у вас нет сконфигурированного закрытого ключа OTR."
::msgcat::mcset ru "%s have sent you an OTR encrypted message, but you can't\
        decipher it because you don't have your OTR private key configured." \
        "%s прислал вам сообщение, зашифрованное с помощью OTR, но вы не\
        можете расшифровать его, так как у вас нет сконфигурированного\
        закрытого ключа OTR."
::msgcat::mcset ru "Advertise your support of OTR using the whitespace tag." \
        "Показывать поддержку OTR, используя метку из пробельных символов."
::msgcat::mcset ru "Allow Tkabber to use Off-the-Record protocol (version 2 or\
        3)." "Разрешить Tkabber'у использовать протокол OTR (версию 2 или 3)."
::msgcat::mcset ru "Allow encryption" "Разрешить шифрование"
::msgcat::mcset ru "Attach whitespace tag" \
        "Прикреплять метку из пробельных символов"
201
202
203
204
205
206
207






208
209
210
211
212
213







214
215
216
217
218
219
220
221
222
223
::msgcat::mcset ru "You don't have a private DSA key for this JID. Either\
        import a 1024 bit DSA private key, or generate one." "У вас нет\
        закрытого ключа DSA для этого JID. Или мпортируйте, или сгенерируйте\
        себе 1024-битный ключ."

::msgcat::mcset ru "Encrypted message can't be deciphered" "Зашифрованное\
        сообщение не удалось расшифровать"






::msgcat::mcset ru "Message is not sent because encryption is required.\
        Trying to start private conversation..." "Сообщение не отправлено,\
        так как шифрование обязательно. Пробуем начать приватный разговор..."
::msgcat::mcset ru "Message is not sent. Either end your private\
        conversation, or restart it" "Сообщение не отправлено. Или\
        завершите защищенный разговор, или начните заново"







::msgcat::mcset ru "Unmatched protocol versions" "Несовпадающие версии\
        протокола"
::msgcat::mcset ru "Private conversation is refreshed" "Защищенный разговор\
        начат заново"
::msgcat::mcset ru "Private conversation is started" "Защищенный разговор\
        начат"
::msgcat::mcset ru "Private conversation is finished" "Защищенный разговор\
        закончен"

# vim:ft=tcl:ts=8:sw=4:sts=4:et







>
>
>
>
>
>






>
>
>
>
>
>
>










211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
::msgcat::mcset ru "You don't have a private DSA key for this JID. Either\
        import a 1024 bit DSA private key, or generate one." "У вас нет\
        закрытого ключа DSA для этого JID. Или мпортируйте, или сгенерируйте\
        себе 1024-битный ключ."

::msgcat::mcset ru "Encrypted message can't be deciphered" "Зашифрованное\
        сообщение не удалось расшифровать"
::msgcat::mcset ru "Last message has been resent" "Последнее сообщение было\
        отослано повторно"
::msgcat::mcset ru "Last message should have been resent but has not because\
        the peer's OTR key has been changed" "Последнее сообщение следовало\
        бы отослать повторно, но оно не было отслано, так как ключ OTR\
        собеседника изменился"
::msgcat::mcset ru "Message is not sent because encryption is required.\
        Trying to start private conversation..." "Сообщение не отправлено,\
        так как шифрование обязательно. Пробуем начать приватный разговор..."
::msgcat::mcset ru "Message is not sent. Either end your private\
        conversation, or restart it" "Сообщение не отправлено. Или\
        завершите защищенный разговор, или начните заново"
::msgcat::mcset ru "OTR request message is received but it uses an\
        incompatible or disabled protocol version" "Получено сообщение с\
        запросом сессии OTR, но в нем используется неподдерживаемая или\
        отключенная версия протокола"
::msgcat::mcset ru "OTR request message is received but you have disabled\
        encryption" "Получено сообщение с запросом сессии OTR, но вы\
        отключили шифрование"
::msgcat::mcset ru "Unmatched protocol versions" "Несовпадающие версии\
        протокола"
::msgcat::mcset ru "Private conversation is refreshed" "Защищенный разговор\
        начат заново"
::msgcat::mcset ru "Private conversation is started" "Защищенный разговор\
        начат"
::msgcat::mcset ru "Private conversation is finished" "Защищенный разговор\
        закончен"

# vim:ft=tcl:ts=8:sw=4:sts=4:et

Changes to otr/msgs/uk.msg.

19
20
21
22
23
24
25










26
27
28
29
30
31
32
::msgcat::mcset uk "Set authenticated" "Відмітити як аутентифікованного"
::msgcat::mcset uk "Unmark for deletion" "Зняти відмітку для видалення"
::msgcat::mcset uk "Unset authenticated" "Відмітити як не аутентифікованного"
::msgcat::mcset uk "Yes" "Так"
::msgcat::mcset uk "Your JID: " "Ваш JID:"

# ./otr.tcl










::msgcat::mcset uk "Advertise your support of OTR using the whitespace tag." \
        "Показувати підтримку OTR, використовуючи мітку з пропускових символів."
::msgcat::mcset uk "Allow Tkabber to use Off-the-Record protocol (version 2 or\
        3)." "Дозволити Tkabber'у використовувати протокол OTR (версію 2 чи 3)."
::msgcat::mcset uk "Allow encryption" "Дозволити ширування"
::msgcat::mcset uk "Attach whitespace tag" \
        "Прикріплювати мітку з пропускових символів"







>
>
>
>
>
>
>
>
>
>







19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
::msgcat::mcset uk "Set authenticated" "Відмітити як аутентифікованного"
::msgcat::mcset uk "Unmark for deletion" "Зняти відмітку для видалення"
::msgcat::mcset uk "Unset authenticated" "Відмітити як не аутентифікованного"
::msgcat::mcset uk "Yes" "Так"
::msgcat::mcset uk "Your JID: " "Ваш JID:"

# ./otr.tcl
::msgcat::mcset ru "%s has requested an Off-the-Record private conversation,\
        but you can't maintain it because you don't have your OTR private key\
        configured." "%s запропонував вам скористатися протоколом OTR для\
        безпечної розмови, але ви не можете його підтримати, тому що\
        у вас немає сконфігурованого закритого ключа OTR."
::msgcat::mcset ru "%s have sent you an OTR encrypted message, but you can't\
        decipher it because you don't have your OTR private key configured." \
        "%s прислав вам повідомлення, зашифроване за допомогою OTR, але ви не\
        можете розшифрувати його, тому що у вас немає сконфігурованого\
        закритого ключа OTR."
::msgcat::mcset uk "Advertise your support of OTR using the whitespace tag." \
        "Показувати підтримку OTR, використовуючи мітку з пропускових символів."
::msgcat::mcset uk "Allow Tkabber to use Off-the-Record protocol (version 2 or\
        3)." "Дозволити Tkabber'у використовувати протокол OTR (версію 2 чи 3)."
::msgcat::mcset uk "Allow encryption" "Дозволити ширування"
::msgcat::mcset uk "Attach whitespace tag" \
        "Прикріплювати мітку з пропускових символів"
203
204
205
206
207
208
209






210
211
212
213
214
215







216
217
218
219
220
221
::msgcat::mcset uk "You don't have a private DSA key for this JID. Either\
        import a 1024 bit DSA private key, or generate one." "У вас немає\
        закритого ключа DSA для цього JID. Або імпортуйте, або згенеруйте\
        собі 1024-бітний ключ."

::msgcat::mcset uk "Encrypted message can't be deciphered" "Зашифроване\
        повідомлення не вдалося розшифрувати"






::msgcat::mcset uk "Message is not sent because encryption is required.\
        Trying to start private conversation..." "Повідомлення не відправлене,\
        тому що шифрування обов’язкове. Спробуємо почати приватну бесіду..."
::msgcat::mcset uk "Message is not sent. Either end your private\
        conversation, or restart it" "Повідомлення не відправлене. Або завершіть\
        захищену розмову, або почніть її заново."







::msgcat::mcset uk "Unmatched protocol versions" "Неспівпадаючі версії протокола"
::msgcat::mcset uk "Private conversation is refreshed" "Захищена розмова почалася заново"
::msgcat::mcset uk "Private conversation is started" "Захищена розмова почалася"
::msgcat::mcset uk "Private conversation is finished" "Захищену розмову завершено"

# vim:ft=tcl:ts=8:sw=4:sts=4:et







>
>
>
>
>
>






>
>
>
>
>
>
>






213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
::msgcat::mcset uk "You don't have a private DSA key for this JID. Either\
        import a 1024 bit DSA private key, or generate one." "У вас немає\
        закритого ключа DSA для цього JID. Або імпортуйте, або згенеруйте\
        собі 1024-бітний ключ."

::msgcat::mcset uk "Encrypted message can't be deciphered" "Зашифроване\
        повідомлення не вдалося розшифрувати"
::msgcat::mcset ru "Last message has been resent" "Останнє повідомлення було\
        відіслане повторно"
::msgcat::mcset ru "Last message should have been resent but has not because\
        the peer's OTR key has been changed" "Останнє повідомлення мало бути\
        відіслане повторно, але воно не було відіслане, тому що ключ OTR\
        співрозмовника змінився"
::msgcat::mcset uk "Message is not sent because encryption is required.\
        Trying to start private conversation..." "Повідомлення не відправлене,\
        тому що шифрування обов’язкове. Спробуємо почати приватну бесіду..."
::msgcat::mcset uk "Message is not sent. Either end your private\
        conversation, or restart it" "Повідомлення не відправлене. Або завершіть\
        захищену розмову, або почніть її заново."
::msgcat::mcset ru "OTR request message is received but it uses an\
        incompatible or disabled protocol version" "Отримане повідомлення з\
        запитом сесії OTR, але в ньому використовується непідтримана або\
        вимкнена версія протоколу"
::msgcat::mcset ru "OTR request message is received but you have disabled\
        encryption" "Отримане повідомлення з запитом сесії OTR, але ви\
        вимкнули шифрування"
::msgcat::mcset uk "Unmatched protocol versions" "Неспівпадаючі версії протокола"
::msgcat::mcset uk "Private conversation is refreshed" "Захищена розмова почалася заново"
::msgcat::mcset uk "Private conversation is started" "Захищена розмова почалася"
::msgcat::mcset uk "Private conversation is finished" "Захищену розмову завершено"

# vim:ft=tcl:ts=8:sw=4:sts=4:et

Changes to otr/otr.tcl.

1046
1047
1048
1049
1050
1051
1052
1053


















1054
1055
1056
1057
1058
1059
1060
    # Work only in chats and normal messages
    if {$type ne "" && $type ne "normal" && $type ne "chat"} return

    # We can't distinguish between bodyless message and message with empty
    # body, so be it
    if {$body eq ""} return

    if {![once_only $xlib $from]} return



















    set result [::otr::incomingMessage $ctx($xlib,$from) $body]

    debugmsg otr "INCOMING MESSAGE: $xlib; $from; $result;"

    array set res $result








|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
    # Work only in chats and normal messages
    if {$type ne "" && $type ne "normal" && $type ne "chat"} return

    # We can't distinguish between bodyless message and message with empty
    # body, so be it
    if {$body eq ""} return

    if {![once_only $xlib $from]} {
        if {![catch {::otr::data::binaryMessageFragment $body}] || \
                ![catch {::otr::data::binaryMessage $body}]} {
            show_info $xlib $from \
                      [::msgcat::mc "%s have sent you an OTR encrypted\
                                     message, but you can't decipher it\
                                     because you don't have your OTR private\
                                     key configured." $from]
            set body ""
        } elseif {![catch {::otr::data::findQueryMessage $body}]} {
            show_info $xlib $from \
                      [::msgcat::mc "%s has requested an Off-the-Record\
                                     private conversation, but you can't\
                                     maintain it because you don't have\
                                     your OTR private key configured." $from]
            set body ""
        }
        return
    }

    set result [::otr::incomingMessage $ctx($xlib,$from) $body]

    debugmsg otr "INCOMING MESSAGE: $xlib; $from; $result;"

    array set res $result