2025-05-05 20:40 ftp://ftp.de.debian.org/debian/pool/main/libp/libpam-tacplus/libpam-tacplus_1.3.8.orig.tar.gz cppcheck-options: --library=posix --library=gnu --library=bsd --inconclusive --enable=style,information --inline-suppr --template=daca2 --disable=missingInclude --suppress=unmatchedSuppression --check-library --debug-warnings --suppress=autoNoType --suppress=valueFlowBailout --suppress=bailoutUninitVar --suppress=symbolDatabaseWarning --suppress=normalCheckLevelConditionExpressions -D__GNUC__ --platform=unix64 -j1 platform: Linux-6.8.0-59-generic-x86_64-with-glibc2.39 python: 3.12.3 client-version: 1.3.67 compiler: g++ (Ubuntu 14.2.0-4ubuntu2~24.04) 14.2.0 cppcheck: head 2.17.0 head-info: 581f101 (2025-05-05 21:13:30 +0200) count: 79 78 elapsed-time: 0.8 0.7 head-timing-info: old-timing-info: head results: pam_tacplus-1.3.8/libtac/lib/acct_r.c:71:9: error: There is an unknown macro here somewhere. Configuration is required. If TACDEBUG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/acct_s.c:177:5: error: There is an unknown macro here somewhere. Configuration is required. If TACDEBUG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/attrib.c:44:9: error: There is an unknown macro here somewhere. Configuration is required. If TACSYSLOG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/authen_r.c:121:9: error: There is an unknown macro here somewhere. Configuration is required. If TACDEBUG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/authen_s.c:168:5: error: There is an unknown macro here somewhere. Configuration is required. If TACDEBUG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/author_r.c:54:9: error: There is an unknown macro here somewhere. Configuration is required. If TACSYSLOG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/author_s.c:166:5: error: There is an unknown macro here somewhere. Configuration is required. If TACDEBUG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/connect.c:61:5: error: There is an unknown macro here somewhere. Configuration is required. If TACDEBUG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/cont_s.c:102:5: error: There is an unknown macro here somewhere. Configuration is required. If TACDEBUG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/crypt.c:39:48: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable tac_secret [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/libtac/lib/crypt.c:85:9: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable tac_secret [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/libtac/lib/crypt.c:50:9: style: Obsolescent function 'bcopy' called. It is recommended to use 'memcpy' or 'memmove' instead. [prohibitedbcopyCalled] pam_tacplus-1.3.8/libtac/lib/crypt.c:52:9: style: Obsolescent function 'bcopy' called. It is recommended to use 'memcpy' or 'memmove' instead. [prohibitedbcopyCalled] pam_tacplus-1.3.8/libtac/lib/crypt.c:54:9: style: Obsolescent function 'bcopy' called. It is recommended to use 'memcpy' or 'memmove' instead. [prohibitedbcopyCalled] pam_tacplus-1.3.8/libtac/lib/crypt.c:56:9: style: Obsolescent function 'bcopy' called. It is recommended to use 'memcpy' or 'memmove' instead. [prohibitedbcopyCalled] pam_tacplus-1.3.8/libtac/lib/crypt.c:61:13: style: Obsolescent function 'bcopy' called. It is recommended to use 'memcpy' or 'memmove' instead. [prohibitedbcopyCalled] pam_tacplus-1.3.8/libtac/lib/crypt.c:50:33: warning:inconclusive: If memory allocation fails, then there is a possible null pointer dereference: buf [nullPointerOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:50:33: note: Null pointer dereference pam_tacplus-1.3.8/libtac/lib/crypt.c:52:30: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:52:30: note: Null pointer addition pam_tacplus-1.3.8/libtac/lib/crypt.c:54:33: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:54:33: note: Null pointer addition pam_tacplus-1.3.8/libtac/lib/crypt.c:56:32: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:56:32: note: Null pointer addition pam_tacplus-1.3.8/libtac/lib/crypt.c:67:21: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:42:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:42:11: note: Assignment 'pad=(u_char*)xcalloc(n,16)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:67:21: note: Null pointer addition pam_tacplus-1.3.8/libtac/lib/crypt.c:29:36: style: Parameter 'hdr' can be declared as pointer to const [constParameterPointer] pam_tacplus-1.3.8/libtac/lib/crypt.c:31:12: style: Variable 'bp' is assigned a value that is never used. [unreadVariable] pam_tacplus-1.3.8/libtac/lib/hdr_check.c:34:9: error: There is an unknown macro here somewhere. Configuration is required. If TACSYSLOG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/libtac/lib/header.c:67:27: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TAC_PLUS_HDR_SIZE [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/libtac/lib/header.c:70:5: warning: If memory allocation fails, then there is a possible null pointer dereference: th [nullPointerOutOfMemory] pam_tacplus-1.3.8/libtac/lib/header.c:67:23: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/header.c:67:8: note: Assignment 'th=(HDR*)xcalloc(1,TAC_PLUS_HDR_SIZE)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/header.c:70:5: note: Null pointer dereference pam_tacplus-1.3.8/libtac/lib/header.c:71:5: warning: If memory allocation fails, then there is a possible null pointer dereference: th [nullPointerOutOfMemory] pam_tacplus-1.3.8/libtac/lib/header.c:67:23: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/header.c:67:8: note: Assignment 'th=(HDR*)xcalloc(1,TAC_PLUS_HDR_SIZE)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/header.c:71:5: note: Null pointer dereference pam_tacplus-1.3.8/libtac/lib/header.c:72:5: warning: If memory allocation fails, then there is a possible null pointer dereference: th [nullPointerOutOfMemory] pam_tacplus-1.3.8/libtac/lib/header.c:67:23: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/header.c:67:8: note: Assignment 'th=(HDR*)xcalloc(1,TAC_PLUS_HDR_SIZE)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/header.c:72:5: note: Null pointer dereference pam_tacplus-1.3.8/libtac/lib/magic.c:60:36: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable O_RDONLY [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/libtac/lib/md5.c:93:53: style: Parameter 'inBuf' can be declared as pointer to const [constParameterPointer] pam_tacplus-1.3.8/libtac/lib/md5.c:169:44: style: Parameter 'in' can be declared as pointer to const [constParameterPointer] pam_tacplus-1.3.8/libtac/lib/read_wait.c:87:12: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable fd [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/libtac/lib/read_wait.c:114:16: style: Condition 'rc<0' is always true [knownConditionTrueFalse] pam_tacplus-1.3.8/libtac/lib/read_wait.c:100:16: note: Assuming that condition 'rc==0' is not redundant pam_tacplus-1.3.8/libtac/lib/read_wait.c:105:16: note: Assuming condition is false pam_tacplus-1.3.8/libtac/lib/read_wait.c:114:16: note: Condition 'rc<0' is always true pam_tacplus-1.3.8/libtac/lib/read_wait.c:46:20: style: Variable 'deltausecs' is reassigned a value before the old one has been used. [redundantAssignment] pam_tacplus-1.3.8/libtac/lib/read_wait.c:43:16: note: deltausecs is assigned pam_tacplus-1.3.8/libtac/lib/read_wait.c:46:20: note: deltausecs is overwritten pam_tacplus-1.3.8/libtac/lib/read_wait.c:33:40: style: Parameter 'newer' can be declared as pointer to const [constParameterPointer] pam_tacplus-1.3.8/libtac/lib/read_wait.c:33:63: style: Parameter 'older' can be declared as pointer to const [constParameterPointer] pam_tacplus-1.3.8/libtac/lib/xalloc.c:28:9: error: There is an unknown macro here somewhere. Configuration is required. If TACSYSLOG is a macro then please configure it. [unknownMacro] pam_tacplus-1.3.8/pam_tacplus.c:59:56: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable tac_attrib [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/pam_tacplus.c:120:18: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAM_SESSION_ERR [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/pam_tacplus.c:265:18: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAM_AUTH_ERR [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/pam_tacplus.c:392:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable LOG_DEBUG [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/pam_tacplus.c:407:30: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAM_AUTH_ERR [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/pam_tacplus.c:598:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable LOG_DEBUG [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/pam_tacplus.c:376:5: style: Obsolescent function 'bzero' called. It is recommended to use 'memset' instead. [prohibitedbzeroCalled] pam_tacplus-1.3.8/pam_tacplus.c:520:15: style: Obsolescent function 'index' called. It is recommended to use 'strchr' instead. [prohibitedindexCalled] pam_tacplus-1.3.8/pam_tacplus.c:522:19: style: Obsolescent function 'index' called. It is recommended to use 'strchr' instead. [prohibitedindexCalled] pam_tacplus-1.3.8/pam_tacplus.c:524:13: style: Obsolescent function 'bcopy' called. It is recommended to use 'memcpy' or 'memmove' instead. [prohibitedbcopyCalled] pam_tacplus-1.3.8/pam_tacplus.c:526:13: style: Obsolescent function 'bcopy' called. It is recommended to use 'memcpy' or 'memmove' instead. [prohibitedbcopyCalled] pam_tacplus-1.3.8/pam_tacplus.c:128:14: style: The if condition is the same as the previous if condition [duplicateCondition] pam_tacplus-1.3.8/pam_tacplus.c:125:14: note: First condition pam_tacplus-1.3.8/pam_tacplus.c:128:14: note: Second condition pam_tacplus-1.3.8/pam_tacplus.c:149:20: style: Condition 'tac_service==NULL' is always false [knownConditionTrueFalse] pam_tacplus-1.3.8/pam_tacplus.c:153:21: style: Condition 'tac_protocol==NULL' is always false [knownConditionTrueFalse] pam_tacplus-1.3.8/pam_tacplus.c:458:20: style: Condition 'tac_service==NULL' is always false [knownConditionTrueFalse] pam_tacplus-1.3.8/pam_tacplus.c:462:21: style: Condition 'tac_protocol==NULL' is always false [knownConditionTrueFalse] pam_tacplus-1.3.8/pam_tacplus.c:68:5: warning: %hu in format string (no. 1) requires 'unsigned short' but the argument type is 'signed short'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:126:9: warning: %u in format string (no. 3) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:126:9: warning: %u in format string (no. 4) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:126:9: warning: %u in format string (no. 5) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:272:9: warning: %u in format string (no. 2) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:272:9: warning: %u in format string (no. 3) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:272:9: warning: %u in format string (no. 4) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:392:9: warning: %u in format string (no. 2) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:392:9: warning: %u in format string (no. 3) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:392:9: warning: %u in format string (no. 4) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:425:9: warning: %u in format string (no. 2) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:425:9: warning: %u in format string (no. 3) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:425:9: warning: %u in format string (no. 4) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:598:9: warning: %u in format string (no. 2) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:598:9: warning: %u in format string (no. 3) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:598:9: warning: %u in format string (no. 4) requires 'unsigned int' but the argument type is 'signed int'. [invalidPrintfArgType_uint] pam_tacplus-1.3.8/pam_tacplus.c:518:15: style: Variable 'sep' can be declared as pointer to const [constVariablePointer] pam_tacplus-1.3.8/pam_tacplus.c:473:12: error: Uninitialized variable: arep [uninitvar] pam_tacplus-1.3.8/support.c:57:19: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAM_SUCCESS [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/support.c:68:33: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAM_TTY [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/support.c:81:33: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAM_RHOST [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/support.c:94:39: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable PAM_CONV [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/support.c:116:17: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable LOG_DEBUG [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/support.c:178:51: debug: valueFlowConditionExpressions bailout: Skipping function due to incomplete variable TAC_PLUS_MAXSERVERS [valueFlowBailoutIncompleteVar] pam_tacplus-1.3.8/support.c:70:15: portability: Non reentrant function 'ttyname' called. For threadsafe applications it is recommended to use the reentrant replacement function 'ttyname_r'. [prohibitedttynameCalled] pam_tacplus-1.3.8/support.c:134:14: style: Condition '!tac_prompt' is always false [knownConditionTrueFalse] diff: 2.17.0 pam_tacplus-1.3.8/libtac/lib/crypt.c:52:30: error:inconclusive: If memory allocation fail: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:52:30: note: Null pointer addition head pam_tacplus-1.3.8/libtac/lib/crypt.c:52:30: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:52:30: note: Null pointer addition 2.17.0 pam_tacplus-1.3.8/libtac/lib/crypt.c:54:33: error:inconclusive: If memory allocation fail: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:54:33: note: Null pointer addition head pam_tacplus-1.3.8/libtac/lib/crypt.c:54:33: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:54:33: note: Null pointer addition 2.17.0 pam_tacplus-1.3.8/libtac/lib/crypt.c:56:32: error:inconclusive: If memory allocation fail: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:56:32: note: Null pointer addition head pam_tacplus-1.3.8/libtac/lib/crypt.c:56:32: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:41:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:41:11: note: Assignment 'buf=(u_char*)xcalloc(1,bufsize)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:56:32: note: Null pointer addition 2.17.0 pam_tacplus-1.3.8/libtac/lib/crypt.c:67:21: error:inconclusive: If memory allocation fail: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:42:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:42:11: note: Assignment 'pad=(u_char*)xcalloc(n,16)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:67:21: note: Null pointer addition head pam_tacplus-1.3.8/libtac/lib/crypt.c:67:21: error:inconclusive: If memory allocation fails: pointer addition with NULL pointer. [nullPointerArithmeticOutOfMemory] pam_tacplus-1.3.8/libtac/lib/crypt.c:42:29: note: Assuming allocation function fails pam_tacplus-1.3.8/libtac/lib/crypt.c:42:11: note: Assignment 'pad=(u_char*)xcalloc(n,16)', assigned value is 0 pam_tacplus-1.3.8/libtac/lib/crypt.c:67:21: note: Null pointer addition head pam_tacplus-1.3.8/pam_tacplus.c:473:12: error: Uninitialized variable: arep [uninitvar] DONE