Josef Cacek created ELY-754:
-------------------------------
Summary: Coverity static analysis: Explicit null dereferenced in
IdentityCredentials (Elytron)
Key: ELY-754
URL:
https://issues.jboss.org/browse/ELY-754
Project: WildFly Elytron
Issue Type: Bug
Reporter: Josef Cacek
Assignee: Darran Lofthouse
Coverity static-analysis scan found possible use of null object in
{{IdentityCredentials.contains(Class)}} method.
https://scan7.coverity.com/reports.htm#v16159/p11778/fileInstanceId=58628...
The method returns
{code}
return contains(credentialType, null);
{code}
If the virtual call resolves to type {{CredentailNode}}, then the {{contains()}} call may
result in NPE, because the {{null}} is used as {{algorthmName}} in:
{code}
return credentialType.isInstance(credential) &&
algorithmName.equals(((AlgorithmCredential) credential).getAlgorithm());
{code}
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)