equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 1997, 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 |
116 * @since 1.2 |
116 * @since 1.2 |
117 */ |
117 */ |
118 |
118 |
119 public final class SignedObject implements Serializable { |
119 public final class SignedObject implements Serializable { |
120 |
120 |
|
121 @java.io.Serial |
121 private static final long serialVersionUID = 720502720485447167L; |
122 private static final long serialVersionUID = 720502720485447167L; |
122 |
123 |
123 /* |
124 /* |
124 * The original content is "deep copied" in its serialized format |
125 * The original content is "deep copied" in its serialized format |
125 * and stored in a byte array. The signature field is also in the |
126 * and stored in a byte array. The signature field is also in the |
248 |
249 |
249 /** |
250 /** |
250 * readObject is called to restore the state of the SignedObject from |
251 * readObject is called to restore the state of the SignedObject from |
251 * a stream. |
252 * a stream. |
252 */ |
253 */ |
|
254 @java.io.Serial |
253 private void readObject(java.io.ObjectInputStream s) |
255 private void readObject(java.io.ObjectInputStream s) |
254 throws java.io.IOException, ClassNotFoundException { |
256 throws java.io.IOException, ClassNotFoundException { |
255 java.io.ObjectInputStream.GetField fields = s.readFields(); |
257 java.io.ObjectInputStream.GetField fields = s.readFields(); |
256 content = ((byte[])fields.get("content", null)).clone(); |
258 content = ((byte[])fields.get("content", null)).clone(); |
257 signature = ((byte[])fields.get("signature", null)).clone(); |
259 signature = ((byte[])fields.get("signature", null)).clone(); |