Bug 90212 - crash at connect ( irc only )
Summary: crash at connect ( irc only )
Status: RESOLVED FIXED
Alias: None
Product: kopete
Classification: Applications
Component: IRC Plugin (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR crash
Target Milestone: ---
Assignee: Kopete Developers
URL:
Keywords:
: 89529 92554 95859 95936 96661 98085 99603 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-09-25 07:14 UTC by Mathieu Jobin
Modified: 2005-02-17 15:01 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
ircssl.diff (1.13 KB, text/x-diff)
2005-01-28 21:07 UTC, Jason Keirstead
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mathieu Jobin 2004-09-25 07:14:18 UTC
Version:           unknown (using KDE 3.3.0, compiled sources)
Compiler:          gcc version 3.2.2 (Mandrake Linux 9.1 3.2.2-3mdk)
OS:                Linux (i686) release 2.4.21-0.13mdk

[New Thread 16384 (LWP 15376)]
[New Thread 32769 (LWP 15382)]
0x41ca76ba in waitpid () from /lib/i686/libpthread.so.0
#0  0x41ca76ba in waitpid () from /lib/i686/libpthread.so.0
#1  0x410a60ad in KCrash::defaultCrashHandler(int) (sig=11) at kcrash.cpp:246
#2  0x41ca65ce in __pthread_sighandler () from /lib/i686/libpthread.so.0
#3  0x41f283b8 in __libc_sigaction () from /lib/i686/libc.so.6
#4  0x40a04ae5 in KSSLCertificate::getSubject() const (this=0x8724828)
    at ksslcertificate.cc:170
#5  0x40a0b318 in KSSLPeerInfo::certMatchesAddress() (this=0x8724828)
    at ksslpeerinfo.cc:67
#6  0x4360406f in KSSLSocket::verifyCertificate() (this=0x8935998)
    at ksslsocket.cpp:263
#7  0x436034d7 in KSSLSocket::slotConnected() (this=0x8935998)
    at ksslsocket.cpp:149
#8  0x436054db in KSSLSocket::qt_invoke(int, QUObject*) (this=0x8935998, 
    _id=7, _o=0xbfffef80) at ksslsocket.moc:96
#9  0x414f138b in QObject::activate_signal(QConnectionList*, QUObject*) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#10 0x414f11fb in QObject::activate_signal(int) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#11 0x410ead1b in KExtendedSocket::connectionSuccess() (this=0x8935998)
    at kextsock.moc:112
#12 0x410e9889 in KExtendedSocket::connectionEvent() (this=0x8935998)
    at kextsock.cpp:1811
#13 0x410e9437 in KExtendedSocket::socketActivityWrite() (this=0x8935998)
    at kextsock.cpp:1729
#14 0x410eae10 in KExtendedSocket::qt_invoke(int, QUObject*) (this=0x8935998, 
    _id=3, _o=0xbffff170) at kextsock.moc:131
#15 0x43605511 in KSSLSocket::qt_invoke(int, QUObject*) (this=0x8935998, 
    _id=3, _o=0xbffff170) at ksslsocket.moc:100
#16 0x414f1417 in QObject::activate_signal(QConnectionList*, QUObject*) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#17 0x414f1566 in QObject::activate_signal(int, int) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#18 0x418a2248 in QSocketNotifier::activated(int) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#19 0x4150e431 in QSocketNotifier::event(QEvent*) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#20 0x41490204 in QApplication::internalNotify(QObject*, QEvent*) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#21 0x4148f889 in QApplication::notify(QObject*, QEvent*) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#22 0x41017996 in KApplication::notify(QObject*, QEvent*) (this=0xbffff6a0, 
    receiver=0x8a49ca0, event=0xbffff410) at kapplication.cpp:495
#23 0x4147e33e in QEventLoop::activateSocketNotifiers() ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#24 0x414376df in QEventLoop::processEvents(unsigned) ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#25 0x414a303f in QEventLoop::enterLoop() ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#26 0x414a2ef4 in QEventLoop::exec() ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#27 0x41490490 in QApplication::exec() ()
   from /home/src/kde/qt-copy/lib/libqt-mt.so.3
#28 0x0806fc0b in main (argc=3, argv=0xbffff824) at main.cpp:100
#29 0x41f157f7 in __libc_start_main () from /lib/i686/libc.so.6
Comment 1 Michel Hermier 2004-09-26 09:51:42 UTC
Sounds to me to be a KSSL related bug.
Are you using cvs HEAD or a KDE release from RH?
It seems that cvs KSSL has changed during the week so I'm not able to compile it now.
Maybe this bug is related to some refactoring?

Comment 2 Mathieu Jobin 2004-09-26 20:54:41 UTC
you are right this is SSL only
I removed checkmark for use SSL and it does not crash anymore.

however I can't connect to FreeNET, only to IRCnet have been able, but this is another topic.

Comment 3 Michel Hermier 2004-09-26 21:16:42 UTC
It was obvious that you used SSL regarding the backtrace.
The main question was: are you using KDE from cvs or what is your release number?
So that I can try to invesigate the SSL bug.

Comment 4 Mathieu Jobin 2004-09-26 21:49:59 UTC
CVS KDE_3_3_BRANCH Sept 21st
Comment 5 Michel Hermier 2004-09-26 22:08:20 UTC
Could be a temporary libkssl brokage, as I said libkssl seems to have been modified a lot recently.
Update your KDE CVS copy sooner or later, and report.
If the bug still remains, I will investigate it more deeply, or reassign it to the KSSL team.

Comment 6 Michel Hermier 2004-11-02 20:08:15 UTC
*** Bug 92554 has been marked as a duplicate of this bug. ***
Comment 7 Giovanni Venturi 2004-11-02 21:14:41 UTC
It happens with KDE CVS 3_3_BRANCH on the 1st November 2004.
Comment 8 Michel Hermier 2004-11-02 21:31:38 UTC
It seems the KSSL team is slow like hell, or is trying to go for next minor ...
Anyway I'm thinking to remove this feature and encoding stuff for a little time.
To let me allow to handle some API changes in CVS.
But the problem is that I won't be able to re-enable SSL for quite a while (lack of SSL in kdecore/network :( ) ...
Comment 9 Matt Rogers 2004-12-27 06:56:43 UTC
*** Bug 95859 has been marked as a duplicate of this bug. ***
Comment 10 Michał Panasiewicz 2004-12-27 07:23:40 UTC
this is mainspring this crash:
PluginData_IRCProtocol_PreferSSL=true
Comment 11 Matt Rogers 2004-12-28 19:29:41 UTC
*** Bug 95936 has been marked as a duplicate of this bug. ***
Comment 12 Jason Keirstead 2005-01-20 02:05:59 UTC
*** Bug 89529 has been marked as a duplicate of this bug. ***
Comment 13 Jason Keirstead 2005-01-20 02:10:30 UTC
*** Bug 96661 has been marked as a duplicate of this bug. ***
Comment 14 Matt Rogers 2005-01-28 17:00:14 UTC
*** Bug 98085 has been marked as a duplicate of this bug. ***
Comment 15 Jason Keirstead 2005-01-28 19:09:39 UTC
CVS commit by brunes: 

Disable SSL support by default, until we can figure out the problem with KSSL and get it fixed

CCMAIL: 90212@bugs.kde.org


  M +7 -0      libkirc/kircengine.cpp   1.15
  M +12 -3     ui/irceditaccount.ui   1.58


--- kdenetwork/kopete/protocols/irc/libkirc/kircengine.cpp  #1.14:1.15
@@ -97,8 +98,14 @@ void Engine::setUseSSL( bool useSSL )
                 if( m_useSSL )
                 {
+                #ifdef KIRC_SSL_SUPPORT
                         m_sock = new KSSLSocket;
                         m_sock->setSocketFlags( KExtendedSocket::inetSocket );
                 }
                 else
+                #else
+                        kdWarning(14120) << "You tried to use SSL, but this version of Kopete was"
+                                " not compiled with IRC SSL support. A normal IRC connection will be attempted." << endl; 
+                }
+                #endif
                 {
                         m_sock = new KExtendedSocket;

--- kdenetwork/kopete/protocols/irc/ui/irceditaccount.ui  #1.57:1.58
@@ -27,4 +27,7 @@
         </size>
     </property>
+    <property name="caption">
+        <string>IRCEditAccountBase</string>
+    </property>
     <hbox>
         <property name="name">
@@ -379,7 +382,13 @@
                                     <cstring>preferSSL</cstring>
                                 </property>
+                                <property name="enabled">
+                                    <bool>false</bool>
+                                </property>
                                 <property name="text">
                                     <string>&amp;Prefer SSL-based connections</string>
                                 </property>
+                                <property name="accel">
+                                    <string>Alt+P</string>
+                                </property>
                             </widget>
                             <widget class="QCheckBox">
@@ -544,7 +553,7 @@
                                     <string>Auto-show anonymous windows</string>
                                 </property>
-                                <property name="disabled">
-                                    <bool>true</bool>
-                                </property>
+                                <property name="disabled" stdset="0">
+                                    <bool>true</bool>
+                                </property>
                             </widget>
                             <widget class="QCheckBox" row="1" column="0">


Comment 16 George Staikos 2005-01-28 19:33:28 UTC
        char *t = d->kossl->X509_NAME_oneline(d->kossl->X509_get_subject_name(d->m_cert), 0, 0);

Where in there is it crashing?
Comment 17 Jason Keirstead 2005-01-28 21:07:42 UTC
Can anyone who can reliably reproduce this bug, try the following patch and 
see if it fixes the problem?

Note: in order to compile SSL support with latest CVS, you need to pass 
-DKIRC_SSL_SUPPORT as an additional paramater to gcc ( ./configure 
CXXFLAGS="$CXXFLAGS -DKIRC_SSL_SUPPORT" )



Created an attachment (id=9333)
ircssl.diff
Comment 18 Jason Keirstead 2005-02-05 00:30:33 UTC
Can anyone who used to experience this bug tell me the IRC server you are using?

I am currently trying to test SSL to get it ready for 3.4, and it seems to work fine, at least on ircs.segfault.org:994
Comment 19 Michel Hermier 2005-02-05 12:56:05 UTC
can you check the segfault when trying to log in a IRC server with SSL enabled 
while the server don't have SSL?

Comment 20 Daniel Moyne 2005-02-05 14:02:34 UTC
Le Samedi 5 Février 2005 00:30, Jason Keirstead a écrit :
> ------- You are receiving this mail because: -------
> You are on the CC list for the bug, or are watching someone who is.
>
> http://bugs.kde.org/show_bug.cgi?id=90212
>
>
>
>
> ------- Additional Comments From jason keirstead org  2005-02-05 00:30
> ------- Can anyone who used to experience this bug tell me the IRC server
> you are using?
>
> I am currently trying to test SSL to get it ready for 3.4, and it seems to
> work fine, at least on ircs.segfault.org:994
no way to connect on this !

Comment 21 Daniel Moyne 2005-02-05 14:43:43 UTC
Le Samedi 5 Février 2005 12:56, Michel Hermier a écrit :
> ------- You are receiving this mail because: -------
> You are on the CC list for the bug, or are watching someone who is.
>
> http://bugs.kde.org/show_bug.cgi?id=90212
>
>
>
>
> ------- Additional Comments From michel.hermier wanadoo fr  2005-02-05
> 12:56 ------- can you check the segfault when trying to log in a IRC server
> with SSL enabled while the server don't have SSL?
Michel, peut-on poursuivre sur un canal Kopete pour des test ? ; si oui lequel

Comment 22 Daniel Moyne 2005-02-05 14:54:04 UTC
Le Samedi 5 Février 2005 12:56, Michel Hermier a écrit :
> ------- You are receiving this mail because: -------
> You are on the CC list for the bug, or are watching someone who is.
>
> http://bugs.kde.org/show_bug.cgi?id=90212
>
>
>
>
> ------- Additional Comments From michel.hermier wanadoo fr  2005-02-05
> 12:56 ------- can you check the segfault when trying to log in a IRC server
> with SSL enabled while the server don't have SSL?
a priori impossible de choisir ircs.segfault.org:994 j'ai 1024 et j'ai l'icone 
en bas à droite qui flashe don problème ; que faut-il essayer exactement ?
Comment 23 Thiago Macieira 2005-02-05 15:57:39 UTC
Please, write in English because there are other people reading these reports who don't speak French.

Also, preferrably, use the web interface for posting comments. Or at least remove the quotation when replying emails.
Comment 24 Michel Hermier 2005-02-05 17:34:18 UTC
Wait a few days that I'll have my dsl connection up and you'll probably see me 
on the channel with the nick: Slayer[RTFM]

Comment 25 Jason Keirstead 2005-02-05 17:37:28 UTC
I am going to re-enable SSL support in CVS after the freeze and close this bug - i definitely can *not* reproduce any crashes in SSL here. Either my patch fixed it, or it was a KSSL problem that went away.
Comment 26 Jason Keirstead 2005-02-05 21:58:58 UTC
CVS commit by brunes: 

Fix a bunch of bugs, including
- Missing signal errors
- Missing numeric replies
- Don't "Error" on unknown replies - there are too many, and they aren't really errors. Dump to kdWarning though..
- Fixed status handling
- Fixed empty password handling
- Re-enable SSL support, tested and working

BUG: 98590
BUG: 97918
BUG: 92454
BUG: 94293
BUG: 71204
BUG: 77239
BUG: 90212


  M +2 -2      ircaccount.cpp   1.132
  M +44 -0     irccontactmanager.cpp   1.39
  M +3 -0      irccontactmanager.h   1.16
  M +60 -12    ircprotocol.cpp   1.204
  M +19 -0     ircprotocol.h   1.94
  M +74 -26    ircusercontact.cpp   1.107
  M +3 -0      ircusercontact.h   1.46
  M +3 -0      libkirc/kircengine.h   1.19
  M +20 -8     libkirc/kircengine_numericreplies.cpp   1.14



Comment 27 Giovanni Venturi 2005-02-06 18:09:53 UTC
> - Re-enable SSL support, tested and working
Are you sure? I just updated my cvs head and installed but I cannot select 
"prefer SSL-based connections" box.

Comment 28 Jason Keirstead 2005-02-06 22:37:20 UTC
CVS commit by brunes: 

Forgot to re-enable checkbox

CCMAIL:90212@bugs.kde.org


  M +0 -3      irceditaccount.ui   1.61


--- kdenetwork/kopete/protocols/irc/ui/irceditaccount.ui  #1.60:1.61
@@ -379,7 +379,4 @@
                                     <cstring>preferSSL</cstring>
                                 </property>
-                                <property name="enabled">
-                                    <bool>false</bool>
-                                </property>
                                 <property name="text">
                                     <string>&amp;Prefer SSL-based connections</string>


Comment 29 Giovanni Venturi 2005-02-06 23:25:31 UTC
Can you explain me how to connect via SSL with Kopete? Because I cannot, maybe 
I do the wrong steps, but in this way Kopete needs more usability to use this 
feature.
Thank you.

Comment 30 Daniel Moyne 2005-02-07 11:06:55 UTC
Le Dimanche 6 Février 2005 23:25, Giovanni Venturi a écrit :
> ------- You are receiving this mail because: -------
> You are on the CC list for the bug, or are watching someone who is.
>
> http://bugs.kde.org/show_bug.cgi?id=90212
>
>
>
>
> ------- Additional Comments From gventuri73 tiscali it  2005-02-06 23:25
> ------- Can you explain me how to connect via SSL with Kopete? Because I
> cannot, maybe I do the wrong steps, but in this way Kopete needs more
> usability to use this feature.
The SSL protocol is set for connexion is the account not the channel ; so it 
is global ; you will see in the account setup in "connection" "Pefer SSL 
connection".
Regards.

Comment 31 Giovanni Venturi 2005-02-07 12:21:52 UTC
If it's so than the bug is not fixed at all. I set "Pefer SSL 
connection" but then I get no SSL connection.

Comment 32 Jason Keirstead 2005-02-07 13:25:41 UTC
You can't just set 'Prefer SSL', you have to, a) be connecting to a network that has SSL capable servers, b) Make sure that server is in your network configuration with the 'SSL' box checked.

All 'Prefer SSL' does is that it will try the servers with SSL capability *first*, no matter what order the servers are in the network config. If the network doesn't have any SSL servers it isn't going to do anything.
Comment 33 Giovanni Venturi 2005-02-07 14:39:14 UTC
Well I tryed, but it doesn't work (I tryed so before you told me to do in that 
way), but if you tested the code before committing it, than ok let this bug 
closed. You are Kopete developers and you know better than anyone if a 
feature works or not, but using Konversation the SSL was ok at once, so I'm 
using that. Maybe Kopete will be better on IRC for KDE 4, but for the moment 
it's not. I haven't so much time free to help Kopete developing, sorry. I 
just told you this things because I like KDE and I think Kopete could be 
better trying to report problems, not for other reason.

Comment 34 Daniel Moyne 2005-02-07 18:26:25 UTC
Le Lundi 7 Février 2005 13:25, Jason Keirstead a écrit :
> ------- You are receiving this mail because: -------
> You are on the CC list for the bug, or are watching someone who is.
>
> http://bugs.kde.org/show_bug.cgi?id=90212
>
>
>
>
> ------- Additional Comments From jason keirstead org  2005-02-07 13:25
> ------- You can't just set 'Prefer SSL', you have to, a) be connecting to a
> network that has SSL capable servers, b) Make sure that server is in your
> network configuration with the 'SSL' box checked.
>
> All 'Prefer SSL' does is that it will try the servers with SSL capability
> *first*, no matter what order the servers are in the network config. If the
> network doesn't have any SSL servers it isn't going to do anything.
so what you are saying is that if you check the SSL box on a server that does 
not support SSL it should not crash ; it this statement correct ?

Comment 35 Matt Rogers 2005-02-17 15:01:01 UTC
*** Bug 99603 has been marked as a duplicate of this bug. ***