Article View: news.software.nntp
Article #87783sigsegv from vsprintf in nntpswitch
From: Etian
Date: Tue, 06 Feb 2018 17:17
Date: Tue, 06 Feb 2018 17:17
42 lines
2041 bytes
2041 bytes
I am trying to run the "commercial" version which was released to the
public after the wrongful take-down of newsservice. I've used the free
version for 10 years.
Software source: https://github.com/tomarus/nntpswitch
It compiles, and the daemon runs fine. But when a client connects, it
is disconnected and a sigsegv is logged in news.err.
I used gdb to trace it to the vsprintf in this function in socket.c:
* writeclient() write to the client
* return 0 on success, -1 on failure
*/
PROTO int writeclient(CLIENT *client, char *str, ...)
{
va_list ap;
char response[cfg.BufSize];
va_start (ap, str);
vsprintf (response, str, ap);
va_end (ap);
return swriteclient(client, response);
}
It is called from this command in nntpd.c:
writeclient(client, "%u %s NNTPSwitch-%s, %u groups available, %s, slot
%u, connections %u\r\n",
client->posting ? 200 : 201,
client->vhost->Banner,
VERSION,
master->numgroups,
client->posting ? "posting allowed" : "no posting",
client->id + 1,
client->concur
);
Any ideas on what might be wrong?
Technical Details
Message-ID:
<32b73$5a79e328$a6aa31a2$27781@news.sonic-news.com>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.(19219).mbox.7z!not-for-mailShow Full Headers
Complete Article Headers
Message-ID: <32b73$5a79e328$a6aa31a2$27781@news.sonic-news.com> Subject: sigsegv from vsprintf in nntpswitch Date: Tue, 6 Feb 2018 11:17:21 -0600 From: Etian <54698212@sonic-news.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.(19219).mbox.7z!not-for-mail Newsgroups: news.software.nntp X-Mozilla-News-Host: news://news.sonic-news.com:119 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@sonic-news.com Organization: www.sonic-news.com Lines: 40 NNTP-Posting-Date: Tue, 06 Feb 2018 17:17:28 +0000 X-Trace: 32b735a79e32830f940727781 X-Received-Body-CRC: 431706562