equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 1996, 2017, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 1996, 2018, 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 |
31 import java.nio.ByteBuffer; |
31 import java.nio.ByteBuffer; |
32 |
32 |
33 import java.security.*; |
33 import java.security.*; |
34 import java.security.SecureRandom; |
34 import java.security.SecureRandom; |
35 import java.security.interfaces.*; |
35 import java.security.interfaces.*; |
|
36 import java.security.spec.*; |
36 |
37 |
37 import sun.security.util.Debug; |
38 import sun.security.util.Debug; |
38 import sun.security.util.DerValue; |
39 import sun.security.util.DerValue; |
39 import sun.security.util.DerInputStream; |
40 import sun.security.util.DerInputStream; |
40 import sun.security.util.DerOutputStream; |
41 import sun.security.util.DerOutputStream; |
368 @Deprecated |
369 @Deprecated |
369 protected void engineSetParameter(String key, Object param) { |
370 protected void engineSetParameter(String key, Object param) { |
370 throw new InvalidParameterException("No parameter accepted"); |
371 throw new InvalidParameterException("No parameter accepted"); |
371 } |
372 } |
372 |
373 |
|
374 @Override |
|
375 protected void engineSetParameter(AlgorithmParameterSpec params) |
|
376 throws InvalidAlgorithmParameterException { |
|
377 if (params != null) { |
|
378 throw new InvalidAlgorithmParameterException("No parameter accepted"); |
|
379 } |
|
380 } |
|
381 |
373 @Deprecated |
382 @Deprecated |
374 protected Object engineGetParameter(String key) { |
383 protected Object engineGetParameter(String key) { |
|
384 return null; |
|
385 } |
|
386 |
|
387 @Override |
|
388 protected AlgorithmParameters engineGetParameters() { |
375 return null; |
389 return null; |
376 } |
390 } |
377 |
391 |
378 |
392 |
379 private BigInteger generateR(BigInteger p, BigInteger q, BigInteger g, |
393 private BigInteger generateR(BigInteger p, BigInteger q, BigInteger g, |