smokku/jabberd2 — Issue #2: IDN causes s2s segfault on connection to punycode domain
Author: stiletto
Created: 2012-02-23 11:04:02+00:00
State: open

When outgoing stanza is addressed to an IDN-domain named by its punycode name "xn--rih.co.cc" and not "⌨.co.cc", s2s segfaults .
```
Thu Feb 23 13:52:02 2012 [notice] [19] [46.151.157.21, port=49709] incoming connection
Thu Feb 23 13:52:02 2012 [notice] [19] [46.151.157.21, port=49709] incoming stream online (id zoxgqu56pwl86rl0iuhhyg52a6d857z5vxmmrrsh)
Thu Feb 23 13:52:02 2012 [notice] [19] [46.151.157.21, port=49709] received dialback auth request for route 'bnw.im/xn--rih.co.cc'
Thu Feb 23 13:52:03 2012 [notice] dns lookup for ⌨.co.cc returned 1 result (ttl 33322)
Thu Feb 23 13:52:21 2012 [notice] [20] [174.129.226.140, port=17149] incoming connection
Thu Feb 23 13:52:21 2012 [notice] [20] [174.129.226.140, port=17149] incoming stream online (id odpu4bvm5c43ta64gjcmrcrnad9251ktf9oklj6r)
Thu Feb 23 13:52:22 2012 [notice] [20] [174.129.226.140, port=17149] received dialback auth request for route 'bnw.im/talkr.im'
Thu Feb 23 13:52:22 2012 [notice] dns lookup for talkr.im returned 1 result (ttl 273)
Thu Feb 23 13:52:22 2012 [notice] [21] [174.129.226.140, port=5269] outgoing connection for 'talkr.im'
Thu Feb 23 13:52:22 2012 [notice] [21] [174.129.226.140, port=5269] sending dialback auth request for route 'bnw.im/talkr.im'
Thu Feb 23 13:52:22 2012 [notice] [22] [174.129.226.140, port=48722] incoming connection
Thu Feb 23 13:52:22 2012 [notice] [22] [174.129.226.140, port=48722] incoming stream online (id bvpl1t2k6objfytt8wy9gsoqg8b0f2wrxldzffjl)
Thu Feb 23 13:52:22 2012 [notice] [22] [174.129.226.140, port=48722] checking dialback verification from talkr.im: sending valid
Thu Feb 23 13:52:22 2012 [notice] [21] [174.129.226.140, port=5269] outgoing route 'bnw.im/talkr.im' is now valid
Thu Feb 23 13:52:22 2012 [notice] [20] [174.129.226.140, port=17149] incoming route 'bnw.im/talkr.im' is now valid
Thu Feb 23 13:52:29 2012 [notice] [23] [93.158.153.208, port=39195] incoming connection
Thu Feb 23 13:52:29 2012 [notice] [23] [93.158.153.208, port=39195] incoming stream online (id 3v4juyc2ubca310kackqfhhd3uci9w4dr8wm79o1)
Thu Feb 23 13:52:29 2012 [notice] [23] [93.158.153.208, port=39195] received dialback auth request for route 'bnw.im/ya.ru'
Thu Feb 23 13:52:29 2012 [notice] dns lookup for ya.ru returned 3 results (ttl 3203)
Thu Feb 23 13:52:29 2012 [notice] [24] [93.158.134.48, port=5269] outgoing connection for 'ya.ru'
Thu Feb 23 13:52:29 2012 [notice] [24] [93.158.134.48, port=5269] sending dialback auth request for route 'bnw.im/ya.ru'
Thu Feb 23 13:52:30 2012 [notice] [25] [93.158.153.206, port=46106] incoming connection
Thu Feb 23 13:52:30 2012 [notice] [25] [93.158.153.206, port=46106] incoming stream online (id 0cp2d9cqu25cjifevxor11jay5h8ujtvwixas90m)
Thu Feb 23 13:52:30 2012 [notice] [25] [93.158.153.206, port=46106] received dialback auth request for route 'bnw.im/ya.ru'
Thu Feb 23 13:52:30 2012 [notice] [25] [93.158.153.206, port=46106] incoming route 'bnw.im/ya.ru' is now valid
Thu Feb 23 13:52:30 2012 [notice] [25] [93.158.153.206, port=46106] checking dialback verification from ya.ru: sending valid
Thu Feb 23 13:52:30 2012 [notice] [24] [93.158.134.48, port=5269] outgoing route 'bnw.im/ya.ru' is now valid
Thu Feb 23 13:52:30 2012 [notice] [23] [93.158.153.208, port=39195] incoming route 'bnw.im/ya.ru' is now valid
Thu Feb 23 13:53:56 2012 [notice] [15] [77.88.57.178, port=42981] disconnect, packets: 3
Thu Feb 23 13:54:01 2012 [notice] dns lookup for xn--rih.co.cc timed out
here it segfaults
```