Accepting request 200845 from home:dmdiss:irssi

please forward to 13.1

OBS-URL: https://build.opensuse.org/request/show/200845
OBS-URL: https://build.opensuse.org/package/show/server:irc/irssi?expand=0&rev=47
This commit is contained in:
2013-09-26 16:25:54 +00:00
committed by Git OBS Bridge
parent 41aad864e9
commit f7d5b6120b
3 changed files with 43 additions and 0 deletions

View File

@@ -0,0 +1,33 @@
From: http://bugs.irssi.org/index.php?do=details&task_id=305
-> http://bugs.irssi.org/index.php?getfile=298
Redraw logic removed.
Index: irssi-0.8.15/src/core/network-openssl.c
===================================================================
--- irssi-0.8.15.orig/src/core/network-openssl.c
+++ irssi-0.8.15/src/core/network-openssl.c
@@ -374,6 +374,16 @@ static GIOFuncs irssi_ssl_channel_funcs
irssi_ssl_get_flags
};
+static int getpass_cb(char *buf, int size, int rwflag, void *keyname)
+{
+ char *pp, prompt[256];
+ snprintf(prompt, 256, "Enter PEM pass phrase:"); // for %s:", keyname);
+ pp = getpass(prompt);
+ strncpy(buf, pp, size);
+ buf[size - 1] = '\0';
+ return(strlen(buf));
+}
+
static gboolean irssi_ssl_init(void)
{
SSL_library_init();
@@ -412,6 +422,8 @@ static GIOChannel *irssi_ssl_get_iochann
scert = convert_home(mycert);
if (mypkey && *mypkey)
spkey = convert_home(mypkey);
+ SSL_CTX_set_default_passwd_cb(ctx, getpass_cb);
+ SSL_CTX_set_default_passwd_cb_userdata(ctx, spkey);
if (! SSL_CTX_use_certificate_file(ctx, scert, SSL_FILETYPE_PEM))
g_warning("Loading of client certificate '%s' failed", mycert);
else if (! SSL_CTX_use_PrivateKey_file(ctx, spkey ? spkey : scert, SSL_FILETYPE_PEM))

View File

@@ -1,3 +1,10 @@
-------------------------------------------------------------------
Thu Sep 26 12:38:58 UTC 2013 - ddiss@suse.com
- irssi-0.8.15-ssl-passphrase.patch
Fix prompt breakage following SSL certificate passphrase prompt;
(bnc#842532).
-------------------------------------------------------------------
Thu Sep 5 17:44:34 CEST 2013 - mls@suse.de

View File

@@ -45,6 +45,8 @@ Source1: irssi.desktop
Source2: irssi.png
Source99: irssi-rpmlintrc
Patch: irssi-0.8.15_ssl_proxy.patch
# PATCH-FIX-OPENSUSE irssi-0.8.15-ssl-passphrase.patch bnc#842532
Patch1: irssi-0.8.15-ssl-passphrase.patch
#
Summary: Modular, Secure, and Well Designed IRC Client
License: GPL-2.0+
@@ -92,6 +94,7 @@ Authors:
%prep
%setup -q
#patch
%patch1 -p1
%build
# cp curses.m4 acinclude.m4