Skip to content

Instantly share code, notes, and snippets.

@dsommers
Created February 17, 2017 23:46
Show Gist options
  • Save dsommers/b24458250731220de79b3cf33630586b to your computer and use it in GitHub Desktop.
Save dsommers/b24458250731220de79b3cf33630586b to your computer and use it in GitHub Desktop.
Request for information in hexchat-otr issue #24
/*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,USA
*/
#include "otr.h"
FORMAT_REC formats[] = {
{ MODULE_NAME, "otr" },
{ NULL, "Keys" },
{ "kg_failed", "Key generation for %s: failed: %s (%s)" },
{ "kg_completed", "Key generation for %s: completed in %d seconds. Reloading keys" },
{ "kg_aborted_dup", "Key generation for %s: aborted. Key generation for %s still in progress" },
{ "kg_aborted_dir", "Key generation for %s: aborted, failed creating directory %s: %s" },
{ "kg_mkdir", "created directory %s" },
{ "kg_pipe", "Key generation for %s: error creating pipe: %s" },
{ "kg_fork", "Key generation for %s: fork() error: %s" },
{ "kg_initiated", "Key generation for %s: initiated. This might take several minutes or on some systems even an hour. If you want to check that something is happening, see if there are two processes of your IRC client." },
{ "kg_exited", "Key generation for %s: child terminated for unknown reason" },
{ "kg_exitsig", "Key generation for %s: child was killed by signal %s" },
{ "kg_pollerr", "Key generation for %s: error poll()ing child: %s" },
{ "kg_abort", "Key generation for %s: aborted" },
{ "kg_needacc", "I need an account name. Try something like /otr genkey mynick@irc.server.net" },
{ "kg_noabort", "No ongoing key generation to abort" },
{ "key_not_found", "no private keys found" },
{ "key_loaded", "private keys loaded" },
{ "key_load_error", "Error loading private keys: %s (%s)" },
{ NULL, "Fingerprints" },
{ "fp_saved", "fingerprints saved" },
{ "fp_save_error", "Error saving fingerprints: %s (%s)" },
{ "fp_not_found", "no fingerprints found" },
{ "fp_loaded", "fingerprints loaded" },
{ "fp_load_error", "Error loading fingerprints: %s (%s)" },
{ "fp_trust", "Trusting fingerprint from %s" },
{ NULL, "Instance Tags" },
{ "instag_saved", "instance tags saved" },
{ "instag_save_error", "Error saving instance tags: %s (%s)" },
{ "instag_not_found", "no instance tags found" },
{ "instag_loaded", "instance tags loaded" },
{ "instag_load_error", "Error loading instance tags: %s (%s)" },
{ NULL, "Callbacks" },
{ "ops_notify_bug", "BUG() in ops_notify" },
{ "ops_notify", "title: %s prim: %s sec: %s" },
{ "ops_display_bug", "BUG() in ops_display" },
{ "ops_display", "msg: %s" },
{ "ops_sec", "gone secure" },
{ "ops_fpcomp", "Your peer is not authenticated. To make sure you're talking to the right guy you can either agree on a secret and use the authentication described in /otr auth, or use the traditional way and compare fingerprints over a secure line (e.g. telephone) and subsequently enter /otr trust. Your fingerprint is: %s. %s's fingerprint: %s" },
{ "ops_insec", "gone insecure" },
{ "ops_still_reply", "still secure (is reply)" },
{ "ops_still_no_reply", "still secure (is not reply)" },
{ "ops_log", "log msg: %s" },
{ "ops_inject", "Couldn't inject message from %s for %s: %s" },
{ "ops_handle_msg", "Message event %s, msg %s" },
{ NULL, "SendingReceiving" },
{ "send_failed", "send failed: msg=%s" },
{ "send_change", "couldn't find context also OTR changed the outgoing message(BUG?)" },
{ "send_fragment", "failed to fragment message: msg=%s" },
{ "send_converted", "OTR converted sent message to %s" },
{ "receive_ignore_query", "ignoring rest of OTR default query msg" },
{ "receive_dequeued", "dequeued msg of length %d" },
{ "receive_queued", "queued msg of length %d" },
{ "receive_ignore", "ignoring protocol message of length %d, acc=%s, from=%s: %s" },
{ "receive_converted", "OTR converted received message" },
{ "otr_better_two", "<b>%s</b> has requested an <a href=\"http://otr.cypherpunks.ca/\">Off-the-Record private conversation</a>. However, you do not have a plugin to support that." },
{ "otr_better_three", "See <a href=\"http://otr.cypherpunks.ca/\">http://otr.cypherpunks.ca/</a> for more information." },
{ NULL, "Context" },
{ "ctx_not_found", "couldn't find context: acc=%s nick=%s" },
{ "ctx_not_create", "couldn't create/find context: acc=%s from=%s" },
{ NULL, "Authentication" },
{ "auth_aborted_ongoing", "Ongoing authentication aborted" },
{ "auth_aborted", "Authentication aborted" },
{ "auth_responding", "Responding to authentication request..." },
{ "auth_initiated", "Initiated authentication..." },
{ "auth_have_old", "%s wanted to authenticate but an old authentication was still ongoing. Old authentication will be aborted, please try again." },
{ "auth_peer", "%s wants to authenticate. Type /otr auth <your-shared-secret> to complete." },
{ "auth_peer_qa", "%s wants to authenticate and asked you \"%s\". Type /otr auth <answer> to complete." },
{ "auth_peer_reply_wrong", "%s replied to an auth we didn't start." },
{ "auth_peer_replied", "%s replied to our auth request..." },
{ "auth_peer_wrong_smp3", "%s sent a wrong authentication message (SMP3)." },
{ "auth_peer_wrong_smp4", "%s sent a wrong authentication message (SMP4)." },
{ "auth_successful", "Authentication successful!" },
{ "auth_failed", "Authentication failed!" },
{ "auth_needenc", "You need to establish an OTR session before you can authenticate." },
{ NULL, "Commands" },
{ "cmd_otr", "We're alive" },
{ "cmd_qnotfound", "Failed: Can't get nick and server of current query window. (Or maybe you're doing this in the status window?)" },
{ "cmd_auth", "Please agree on a secret with your peer and then initiate the authentication with /otr auth <secret> or let him initiate. Should you initiate your peer will after a little while be instructed to enter the secret as well. Once he has done so the authentication will finish up. Should you have both typed in the same secret the authentication should be successful." },
{ "cmd_debug_on", "Debug mode is on" },
{ "cmd_debug_off", "Debug mode is off" },
{ "cmd_finish", "Finished conversation with %s@%s." },
{ "cmd_finishall_none", "No conversations to finish." },
{ "cmd_version", "This is irc-otr version %s" },
{ "peer_finished", "%s has finished the OTR conversation. If you want to continue talking enter /otr finish for plaintext or ?OTR? to restart OTR." },
{ NULL, "Contexts" },
{ "ctx_ctx_unencrypted", "%20s %30s plaintext" },
{ "ctx_ctx_encrypted", "%20s %30s encrypted" },
{ "ctx_ctx_finished", "%20s %30s finished" },
{ "ctx_ctx_unknown", "%20s %30s unknown state(BUG?)" },
{ "ctx_fps_no", "%s %rnot authenticated" },
{ "ctx_fps_smp", "%s authenticated via shared secret (SMP)" },
{ "ctx_fps_man", "%s authenticated manually" },
{ "ctx_noctxs", "No active OTR contexts found" },
{ NULL, "Statusbar" },
{ "st_plaintext", "{sb plaintext}" },
{ "st_untrusted", "{sb %rOTR(not auth'ed)}" },
{ "st_trust_smp", "{sb OTR}" },
{ "st_trust_manual", "{sb OTR}" },
{ "st_smp_incoming", "{sb {hilight incoming auth request...}}" },
{ "st_smp_outgoing", "{sb {hilight awaiting auth reply...}}" },
{ "st_smp_finalize", "{sb {hilight finalizing auth...}}" },
{ "st_smp_unknown", "{sb {hilight unknown auth state!}}" },
{ "st_finished", "{sb finished}" },
{ "st_unknown", "{sb {hilight state unknown (BUG!)}}" },
{ NULL, NULL }
};
G_STATIC_ASSERT (G_N_ELEMENTS(formats) - 1 == TXT_ST_UNKNOWN + 1);
/*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,USA
*/
enum
{
TXT_OTR_MODULE_NAME,
TXT_OTR_FILL_0,
TXT_KG_FAILED,
TXT_KG_COMPLETED,
TXT_KG_ABORTED_DUP,
TXT_KG_ABORTED_DIR,
TXT_KG_MKDIR,
TXT_KG_PIPE,
TXT_KG_FORK,
TXT_KG_INITIATED,
TXT_KG_EXITED,
TXT_KG_EXITSIG,
TXT_KG_POLLERR,
TXT_KG_ABORT,
TXT_KG_NEEDACC,
TXT_KG_NOABORT,
TXT_KEY_NOT_FOUND,
TXT_KEY_LOADED,
TXT_KEY_LOAD_ERROR,
TXT_OTR_FILL_1,
TXT_FP_SAVED,
TXT_FP_SAVE_ERROR,
TXT_FP_NOT_FOUND,
TXT_FP_LOADED,
TXT_FP_LOAD_ERROR,
TXT_FP_TRUST,
TXT_OTR_FILL_2,
TXT_INSTAG_SAVED,
TXT_INSTAG_SAVE_ERROR,
TXT_INSTAG_NOT_FOUND,
TXT_INSTAG_LOADED,
TXT_INSTAG_LOAD_ERROR,
TXT_OTR_FILL_3,
TXT_OPS_NOTIFY_BUG,
TXT_OPS_NOTIFY,
TXT_OPS_DISPLAY_BUG,
TXT_OPS_DISPLAY,
TXT_OPS_SEC,
TXT_OPS_FPCOMP,
TXT_OPS_INSEC,
TXT_OPS_STILL_REPLY,
TXT_OPS_STILL_NO_REPLY,
TXT_OPS_LOG,
TXT_OPS_INJECT,
TXT_OPS_HANDLE_MSG,
TXT_OTR_FILL_4,
TXT_SEND_FAILED,
TXT_SEND_CHANGE,
TXT_SEND_FRAGMENT,
TXT_SEND_CONVERTED,
TXT_RECEIVE_IGNORE_QUERY,
TXT_RECEIVE_DEQUEUED,
TXT_RECEIVE_QUEUED,
TXT_RECEIVE_IGNORE,
TXT_RECEIVE_CONVERTED,
TXT_OTR_BETTER_TWO,
TXT_OTR_BETTER_THREE,
TXT_OTR_FILL_5,
TXT_CTX_NOT_FOUND,
TXT_CTX_NOT_CREATE,
TXT_OTR_FILL_6,
TXT_AUTH_ABORTED_ONGOING,
TXT_AUTH_ABORTED,
TXT_AUTH_RESPONDING,
TXT_AUTH_INITIATED,
TXT_AUTH_HAVE_OLD,
TXT_AUTH_PEER,
TXT_AUTH_PEER_QA,
TXT_AUTH_PEER_REPLY_WRONG,
TXT_AUTH_PEER_REPLIED,
TXT_AUTH_PEER_WRONG_SMP3,
TXT_AUTH_PEER_WRONG_SMP4,
TXT_AUTH_SUCCESSFUL,
TXT_AUTH_FAILED,
TXT_AUTH_NEEDENC,
TXT_OTR_FILL_7,
TXT_CMD_OTR,
TXT_CMD_QNOTFOUND,
TXT_CMD_AUTH,
TXT_CMD_DEBUG_ON,
TXT_CMD_DEBUG_OFF,
TXT_CMD_FINISH,
TXT_CMD_FINISHALL_NONE,
TXT_CMD_VERSION,
TXT_PEER_FINISHED,
TXT_OTR_FILL_8,
TXT_CTX_CTX_UNENCRYPTED,
TXT_CTX_CTX_ENCRYPTED,
TXT_CTX_CTX_FINISHED,
TXT_CTX_CTX_UNKNOWN,
TXT_CTX_FPS_NO,
TXT_CTX_FPS_SMP,
TXT_CTX_FPS_MAN,
TXT_CTX_NOCTXS,
TXT_OTR_FILL_9,
TXT_ST_PLAINTEXT,
TXT_ST_UNTRUSTED,
TXT_ST_TRUST_SMP,
TXT_ST_TRUST_MANUAL,
TXT_ST_SMP_INCOMING,
TXT_ST_SMP_OUTGOING,
TXT_ST_SMP_FINALIZE,
TXT_ST_SMP_UNKNOWN,
TXT_ST_FINISHED,
TXT_ST_UNKNOWN
};
extern FORMAT_REC formats[];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment