src/java.base/share/classes/sun/security/provider/DSAPublicKeyImpl.java
changeset 57950 4612a3cfb927
parent 47216 71c04702a3d5
equal deleted inserted replaced
57945:e09c993ac476 57950:4612a3cfb927
     1 /*
     1 /*
     2  * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2005, 2019, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Oracle designates this
     7  * published by the Free Software Foundation.  Oracle designates this
    40  *
    40  *
    41  */
    41  */
    42 
    42 
    43 public final class DSAPublicKeyImpl extends DSAPublicKey {
    43 public final class DSAPublicKeyImpl extends DSAPublicKey {
    44 
    44 
       
    45     @java.io.Serial
    45     private static final long serialVersionUID = 7819830118247182730L;
    46     private static final long serialVersionUID = 7819830118247182730L;
    46 
    47 
    47     /**
    48     /**
    48      * Make a DSA public key out of a public key and three parameters.
    49      * Make a DSA public key out of a public key and three parameters.
    49      * The p, q, and g parameters may be null, but if so, parameters will need
    50      * The p, q, and g parameters may be null, but if so, parameters will need
    68      */
    69      */
    69     public DSAPublicKeyImpl(byte[] encoded) throws InvalidKeyException {
    70     public DSAPublicKeyImpl(byte[] encoded) throws InvalidKeyException {
    70         super(encoded);
    71         super(encoded);
    71     }
    72     }
    72 
    73 
       
    74     @java.io.Serial
    73     protected Object writeReplace() throws java.io.ObjectStreamException {
    75     protected Object writeReplace() throws java.io.ObjectStreamException {
    74         return new KeyRep(KeyRep.Type.PUBLIC,
    76         return new KeyRep(KeyRep.Type.PUBLIC,
    75                         getAlgorithm(),
    77                         getAlgorithm(),
    76                         getFormat(),
    78                         getFormat(),
    77                         getEncoded());
    79                         getEncoded());