1 /* 2 * One-time password login capability 3 * 4 * This file is just a variant of otpw.c, in which the debugging 5 * messages are directed to the log_message function of pam_otpw.c 6 * instead of to stderr. Link otpw-l.o instead of otpw.o into 7 * pam_otpw.so for debugging purposes. 8 * 9 * Markus Kuhn <http://www.cl.cam.ac.uk/~mgk25/> 10 */ 11 12 13 #include <syslog.h> 14 15 16 #ifndef DEBUG_LOG 17 extern void log_message(int priority, void *pamh, 18 const char *format, ...); 19 #define DEBUG_LOG(...) if (ch->flags & OTPW_DEBUG) \ 20 log_message(LOG_DEBUG, (void *) 0, __VA_ARGS__) 21 #endif 22 23 #include "otpw.c" 24