On Wed, Nov 29, 2017 at 02:43:45AM +0100, Jeremie Courreges-Anglas wrote: > On Wed, Nov 29 2017, Claudio Jeker <cje...@diehard.n-r-g.com> wrote: > > On Wed, Nov 29, 2017 at 01:59:06AM +0100, Claudio Jeker wrote: > >> Seen in my log file: > >> Nov 28 17:47:22 dramaqueen iked: vfprintf %s NULL in "%s: %s %s from %s to > >> %s ms gid %u, %ld bytes%s" > >> > >> and > >> > >> Nov 29 01:02:39 dramaqueen iked[49967]: ikev2_msg_send: IKE_SA_INIT > >> request from (null) to 62.48.30.5:500 msgid 0, 438 bytes > >> > >> The problem seems to be in print_host so try to not return NULL in there. > >> Maybe we could return something else but this is a start IMO. > > > > beck@ prefers to just print unknown instead of the gai_strerror -- guess > > that is more sensible. > > Why would getnameinfo(NI_NUMERICHOST) fail here? The code in > ikev2_msg.c is: > > --8<-- > log_info("%s: %s %s from %s to %s msgid %u, %ld bytes%s", __func__, > print_map(exchange, ikev2_exchange_map), > (flags & IKEV2_FLAG_RESPONSE) ? "response" : "request", > print_host((struct sockaddr *)&msg->msg_local, NULL, 0), > print_host((struct sockaddr *)&msg->msg_peer, NULL, 0), > betoh32(hdr->ike_msgid), > ibuf_length(buf), isnatt ? ", NAT-T" : ""); > -->8-- > > Maybe msg->msg_local is corrupt? >
I assume so much. gai_strerror returns "system error" not very helpful. -- :wq Claudio