<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.1//EN' 'http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd'>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head><title>softhsm-2.0.0GITa923913-1.fc21</title></head>
<body>
<h1>softhsm-2.0.0GITa923913-1.fc21</h1>
<h2>List of Defects</h2>
<pre style='white-space: pre-wrap;'>
<a name='def1'/><b>Error: <span style='background: #C0FF00;'>RESOURCE_LEAK</span> (CWE-772):</b> <a href ='#def1'>[#def1]</a>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/bin/common/library.cpp:98: <b>alloc_fn</b>: Storage is returned from allocation function "dlopen".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/bin/common/library.cpp:98: <b>var_assign</b>: Assigning: "pDynLib" = storage returned from "dlopen("/usr/lib64/pkcs11/libsofthsm2.so", 2)".</span>
softhsm-2.0.0GITa923913/src/bin/common/library.cpp:105: <b>leaked_storage</b>: Variable "pDynLib" going out of scope leaks the storage it points to.

<a name='def2'/><b>Error: <span style='background: #C0FF00;'>RESOURCE_LEAK</span> (CWE-772):</b> <a href ='#def2'>[#def2]</a>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/bin/common/library.cpp:94: <b>alloc_fn</b>: Storage is returned from allocation function "dlopen".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/bin/common/library.cpp:94: <b>var_assign</b>: Assigning: "pDynLib" = storage returned from "dlopen(module, 2)".</span>
softhsm-2.0.0GITa923913/src/bin/common/library.cpp:105: <b>leaked_storage</b>: Variable "pDynLib" going out of scope leaks the storage it points to.

<a name='def3'/><b>Error: <span style='background: #C0FF00;'>DEADCODE</span> (CWE-561):</b> <a href ='#def3'>[#def3]</a>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2046: <b>assignment</b>: Assigning: "isRSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2050: <b>assignment</b>: Assigning: "isRSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2058: <b>assignment</b>: Assigning: "isRSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2066: <b>const</b>: At condition "isRSA", the value of "isRSA" must be equal to 1.</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2066: <b>dead_error_condition</b>: The condition "isRSA" must be true.</span>
softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2087: <b>dead_error_line</b>: Execution cannot reach this statement: "return 112UL;".

<a name='def4'/><b>Error: <span style='background: #C0FF00;'>DEADCODE</span> (CWE-561):</b> <a href ='#def4'>[#def4]</a>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2640: <b>assignment</b>: Assigning: "isRSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2644: <b>assignment</b>: Assigning: "isRSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2665: <b>assignment</b>: Assigning: "isRSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2673: <b>const</b>: At condition "isRSA", the value of "isRSA" must be equal to 1.</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2673: <b>dead_error_condition</b>: The condition "isRSA" must be true.</span>
softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2694: <b>dead_error_line</b>: Execution cannot reach this statement: "return 112UL;".

<a name='def5'/><b>Error: <span style='background: #C0FF00;'>DEADCODE</span> (CWE-561):</b> <a href ='#def5'>[#def5]</a>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:3491: <b>assignment</b>: Assigning: "isECDSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:3549: <b>const</b>: At condition "isECDSA", the value of "isECDSA" must be equal to 1.</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:3549: <b>dead_error_condition</b>: The condition "isECDSA" must be true.</span>
softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:3589: <b>dead_error_line</b>: Execution cannot reach this statement: "return 112UL;".

<a name='def6'/><b>Error: <span style='background: #C0FF00;'>DEADCODE</span> (CWE-561):</b> <a href ='#def6'>[#def6]</a>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:4304: <b>assignment</b>: Assigning: "isECDSA" = "true".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:4362: <b>const</b>: At condition "isECDSA", the value of "isECDSA" must be equal to 1.</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:4362: <b>dead_error_condition</b>: The condition "isECDSA" must be true.</span>
softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:4402: <b>dead_error_line</b>: Execution cannot reach this statement: "return 112UL;".

<a name='def7'/><b>Error: <span style='background: #C0FF00;'>CHECKED_RETURN</span> (CWE-252):</b> <a href ='#def7'>[#def7]</a>
softhsm-2.0.0GITa923913/src/lib/crypto/OSSLEVPHashAlgorithm.cpp:61: <b>check_return</b>: Calling "hashFinal" without checking return value (as is done elsewhere 11 out of 13 times).
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:3130: <b>example_checked</b>: Example 1: "session->getDigestOp()->hashFinal(digest)" has its value checked in "session->getDigestOp()->hashFinal(digest) == 0".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2986: <b>example_checked</b>: Example 2: "session->getDigestOp()->hashFinal(digest)" has its value checked in "session->getDigestOp()->hashFinal(digest) == 0".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLDSA.cpp:390: <b>example_assign</b>: Example 3: Assigning: "bFirstResult" = return value from "this->pCurrentHash->hashFinal(hash)".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLDSA.cpp:395: <b>example_checked</b>: Example 3 (cont.): "bFirstResult" has its value checked in "bFirstResult".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLEVPHashAlgorithm.cpp:99: <b>example_checked</b>: Example 4: "this->HashAlgorithm::hashFinal(hashedData)" has its value checked in "this->HashAlgorithm::hashFinal(hashedData)".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLRSA.cpp:890: <b>example_assign</b>: Example 5: Assigning: "bFirstResult" = return value from "this->pCurrentHash->hashFinal(firstHash)".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLRSA.cpp:903: <b>example_checked</b>: Example 5 (cont.): "bFirstResult" has its value checked in "bFirstResult".</span>

<a name='def8'/><b>Error: <span style='background: #C0FF00;'>CHECKED_RETURN</span> (CWE-252):</b> <a href ='#def8'>[#def8]</a>
softhsm-2.0.0GITa923913/src/lib/crypto/OSSLEVPHashAlgorithm.cpp:89: <b>check_return</b>: Calling "hashFinal" without checking return value (as is done elsewhere 11 out of 13 times).
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:3130: <b>example_checked</b>: Example 1: "session->getDigestOp()->hashFinal(digest)" has its value checked in "session->getDigestOp()->hashFinal(digest) == 0".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/SoftHSM.cpp:2986: <b>example_checked</b>: Example 2: "session->getDigestOp()->hashFinal(digest)" has its value checked in "session->getDigestOp()->hashFinal(digest) == 0".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLDSA.cpp:390: <b>example_assign</b>: Example 3: Assigning: "bFirstResult" = return value from "this->pCurrentHash->hashFinal(hash)".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLDSA.cpp:395: <b>example_checked</b>: Example 3 (cont.): "bFirstResult" has its value checked in "bFirstResult".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLEVPHashAlgorithm.cpp:99: <b>example_checked</b>: Example 4: "this->HashAlgorithm::hashFinal(hashedData)" has its value checked in "this->HashAlgorithm::hashFinal(hashedData)".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLRSA.cpp:890: <b>example_assign</b>: Example 5: Assigning: "bFirstResult" = return value from "this->pCurrentHash->hashFinal(firstHash)".</span>
<span style='color: #808080;'>softhsm-2.0.0GITa923913/src/lib/crypto/OSSLRSA.cpp:903: <b>example_checked</b>: Example 5 (cont.): "bFirstResult" has its value checked in "bFirstResult".</span>

</pre>
<h2>Scan Properties</h2>
<table style='font-family: monospace;'>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>analyzer-version-coverity</td><td>7.6.1</td></tr>
<tr><td style='padding-right: 8px;'>analyzer-version-gcc</td><td>5.0.0</td></tr>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>cov-compilation-unit-count</td><td>197</td></tr>
<tr><td style='padding-right: 8px;'>cov-compilation-unit-ratio</td><td>100</td></tr>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>cov-lines-processed</td><td>117396</td></tr>
<tr><td style='padding-right: 8px;'>cov-time-elapsed-analysis</td><td>00:00:22</td></tr>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>exit-code</td><td>0</td></tr>
<tr><td style='padding-right: 8px;'>host</td><td>cov01.lab.eng.brq.redhat.com</td></tr>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>mock-config</td><td>fedora-rawhide-x86_64</td></tr>
<tr><td style='padding-right: 8px;'>store-results-to</td><td>/tmp/tmpQv6zIN/softhsm-2.0.0GITa923913-1.fc21.tar.xz</td></tr>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>time-created</td><td>2015-03-27 13:13:05</td></tr>
<tr><td style='padding-right: 8px;'>time-finished</td><td>2015-03-27 13:17:05</td></tr>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>tool</td><td>csmock</td></tr>
<tr><td style='padding-right: 8px;'>tool-args</td><td>'/usr/bin/csmock' '-t' 'gcc,coverity' '-o' '/tmp/tmpQv6zIN/softhsm-2.0.0GITa923913-1.fc21.tar.xz' '-r' 'fedora-rawhide-x86_64' '--cov-analyze-opts=--concurrency --security' '-w1' '/tmp/tmpQv6zIN/softhsm-2.0.0GITa923913-1.fc21.src.rpm'</td></tr>
<tr style='background-color: #EEE;'><td style='padding-right: 8px;'>tool-version</td><td>csmock-1.7.2.20150326.172734.g2314a19-1.el6</td></tr>
</table>
</body>
</html>