mirror of
https://github.com/openjdk/jdk18u.git
synced 2025-12-11 03:33:57 -06:00
8281388: Change wrapping of EncryptedPrivateKeyInfo
Backport-of: 405381ce9b44c8b122a06e590e4d8240fd9ba996
This commit is contained in:
parent
855bd85983
commit
80000b5096
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2001, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -83,12 +83,12 @@ public class EncryptedPrivateKeyInfo {
|
||||
"must be non-null");
|
||||
}
|
||||
|
||||
DerValue val = new DerValue(encoded);
|
||||
this.encoded = encoded.clone();
|
||||
DerValue val = DerValue.wrap(this.encoded);
|
||||
if (val.tag != DerValue.tag_Sequence) {
|
||||
throw new IOException("DER header error: no SEQ tag");
|
||||
}
|
||||
|
||||
this.encoded = encoded.clone();
|
||||
DerValue[] seq = new DerValue[2];
|
||||
|
||||
seq[0] = val.data.getDerValue();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user