[jboss-jira] [JBoss JIRA] (WFLY-7967) Coverity: Incorrect definition of RawKey as a parent of Serializable classes
Martin Choma (JIRA)
issues at jboss.org
Wed Jan 25 08:12:00 EST 2017
[ https://issues.jboss.org/browse/WFLY-7967?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Choma updated WFLY-7967:
-------------------------------
Description:
There are some Serializable classes, which extends from RawKey, which is not Serializable.
* RawRSAPrivateKey
* RawDHPrivateKey
* RawPBEKey
* RawECPrivateKey
* RawDSAPrivateKey
Either mark RawKey as Serializable as well or if this is not desired, provide no-args constructor in RawKey class, as javadoc describes:
??During deserialization, the fields of non-serializable classes will be initialized using the public or protected no-arg constructor of the class. A no-arg constructor must be accessible to the subclass that is serializable. The fields of serializable subclasses will be restored from the stream. [1]??
[1] http://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html
https://scan7.coverity.com/reports.htm#v23632/p11778/fileInstanceId=8553919&defectInstanceId=2138989&mergedDefectId=1377488
was:
There are some Serializable classes, which extends from RawKey, which is not Serializable.
* RawRSAPrivateKey
* RawDHPrivateKey
* RawPBEKey
* RawECPrivateKey
* RawDSAPrivateKey
Either mark RawKey as Serializable as well or if this is not desired, provide no-args constructor in RawKey class, as javadoc describes:
During deserialization, the fields of non-serializable classes will be initialized using the public or protected no-arg constructor of the class. A no-arg constructor must be accessible to the subclass that is serializable. The fields of serializable subclasses will be restored from the stream. [1]
[1] http://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html
https://scan7.coverity.com/reports.htm#v23632/p11778/fileInstanceId=8553919&defectInstanceId=2138989&mergedDefectId=1377488
> Coverity: Incorrect definition of RawKey as a parent of Serializable classes
> ----------------------------------------------------------------------------
>
> Key: WFLY-7967
> URL: https://issues.jboss.org/browse/WFLY-7967
> Project: WildFly
> Issue Type: Bug
> Components: Security
> Reporter: Martin Choma
> Assignee: Ilia Vassilev
>
> There are some Serializable classes, which extends from RawKey, which is not Serializable.
> * RawRSAPrivateKey
> * RawDHPrivateKey
> * RawPBEKey
> * RawECPrivateKey
> * RawDSAPrivateKey
> Either mark RawKey as Serializable as well or if this is not desired, provide no-args constructor in RawKey class, as javadoc describes:
> ??During deserialization, the fields of non-serializable classes will be initialized using the public or protected no-arg constructor of the class. A no-arg constructor must be accessible to the subclass that is serializable. The fields of serializable subclasses will be restored from the stream. [1]??
> [1] http://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html
> https://scan7.coverity.com/reports.htm#v23632/p11778/fileInstanceId=8553919&defectInstanceId=2138989&mergedDefectId=1377488
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
More information about the jboss-jira
mailing list