K 10
svn:author
V 6
iulius
K 8
svn:date
V 27
2012-06-12T21:10:06.075137Z
K 7
svn:log
V 841
auth_init() should be optional in perl_auth

The documentation (doc/hook-perl) for nnrpd auth hook says:

	If a Perl function auth_init() is defined by that file, it is 
	called immediately after the file is loaded.

And later:

	Provided the file loads without errors, auth_init() (if present) 
	runs without fatal errors, and a Perl function authenticate() is 
	defined, authenticate() will then be called

This suggests that auth_init() is optional, but it actually isn't.  When 
it's not defined, the auth hook will fail:

200 isis.rt.uk.eu.org InterNetNews NNRP server INN 2.5.2 ready (posting ok)
authinfo user test
381 Enter password
authinfo pass test
400 Internal error (3).  Goodbye!

It seems more sensible to not require an auth_init() function, as most
hooks probably won't need it.

Thanks to River Tarnell for the bug report.

END
