5050import org .bouncycastle .jcajce .provider .asymmetric .util .ECUtil ;
5151import org .bouncycastle .operator .OperatorCreationException ;
5252import org .cesecore .certificates .util .AlgorithmTools ;
53- import com . keyfactor . util .keys .token .CryptoTokenAuthenticationFailedException ;
54- import com . keyfactor . util . keys .token .pkcs11 .Pkcs11SlotLabelType ;
55- import com . keyfactor . util . keys .token .pkcs11 .NoSuchSlotException ;
53+ import org . cesecore .keys .token .CryptoTokenAuthenticationFailedException ;
54+ import org . cesecore . keys .token .p11 .Pkcs11SlotLabelType ;
55+ import org . cesecore . keys .token .p11 . exception .NoSuchSlotException ;
5656import org .cesecore .util .query .QueryCriteria ;
5757import org .signserver .common .CryptoTokenAuthenticationFailureException ;
5858import org .signserver .common .CryptoTokenInitializationFailureException ;
@@ -291,7 +291,7 @@ public void init(int workerId, Properties props, org.signserver.server.IServices
291291 // don't initialize keystore delegator when not auto-activated
292292 }
293293
294- } catch (com . keyfactor . util .keys .token .CryptoTokenOfflineException | NumberFormatException ex ) {
294+ } catch (org . cesecore .keys .token .CryptoTokenOfflineException | NumberFormatException ex ) {
295295 LOG .error ("Init failed" , ex );
296296 throw new CryptoTokenInitializationFailureException (ex .getMessage ());
297297 } catch (NoSuchSlotException ex ) {
@@ -326,7 +326,7 @@ public int getCryptoTokenStatus(IServices services) {
326326 }
327327 }
328328 }
329- } catch (com . keyfactor . util .keys .token .CryptoTokenOfflineException | NoSuchAlgorithmException | NoSuchProviderException | InvalidKeyException | SignatureException | ProviderException | OperatorCreationException | IOException ex ) {
329+ } catch (org . cesecore .keys .token .CryptoTokenOfflineException | NoSuchAlgorithmException | NoSuchProviderException | InvalidKeyException | SignatureException | ProviderException | OperatorCreationException | IOException ex ) {
330330 LOG .error ("Error testing activation" , ex );
331331 }
332332 }
@@ -339,7 +339,7 @@ public void activate(String authenticationcode, IServices services) throws Crypt
339339 try {
340340 delegate .activate (authenticationcode .toCharArray ());
341341 keystoreDelegator = new JavaKeyStoreDelegator (delegate .getActivatedKeyStore ());
342- } catch (com . keyfactor . util .keys .token .CryptoTokenOfflineException ex ) {
342+ } catch (org . cesecore .keys .token .CryptoTokenOfflineException ex ) {
343343 LOG .error ("Activate failed" , ex );
344344 throw new CryptoTokenOfflineException (ex );
345345 } catch (CryptoTokenAuthenticationFailedException ex ) {
@@ -368,7 +368,7 @@ public boolean deactivate(IServices services) throws CryptoTokenOfflineException
368368 private PrivateKey getPrivateKey (String alias ) throws CryptoTokenOfflineException {
369369 try {
370370 return delegate .getPrivateKey (alias );
371- } catch (com . keyfactor . util .keys .token .CryptoTokenOfflineException ex ) {
371+ } catch (org . cesecore .keys .token .CryptoTokenOfflineException ex ) {
372372 throw new CryptoTokenOfflineException (ex );
373373 }
374374 }
@@ -402,7 +402,7 @@ public ICertReqData genCertificateRequest(ISignerCertReqInfo info,
402402 }
403403 try {
404404 return CryptoTokenHelper .genCertificateRequest (info , delegate .getPrivateKey (alias ), getProvider (ICryptoTokenV4 .PROVIDERUSAGE_SIGN ), delegate .getPublicKey (alias ), explicitEccParameters );
405- } catch (com . keyfactor . util .keys .token .CryptoTokenOfflineException e ) {
405+ } catch (org . cesecore .keys .token .CryptoTokenOfflineException e ) {
406406 LOG .error ("Certificate request error: " + e .getMessage (), e );
407407 throw new CryptoTokenOfflineException (e );
408408 } catch (IllegalArgumentException ex ) {
@@ -482,7 +482,7 @@ private void generateKeyPair(String keyAlgorithm, String keySpec, String alias,
482482 final KeyStore ks = delegate .getActivatedKeyStore ();
483483 CryptoTokenHelper .regenerateCertIfWanted (alias , authCode , params , keystoreDelegator , ks .getProvider ().getName ());
484484 }
485- } catch (InvalidAlgorithmParameterException | com . keyfactor . util .keys .token .CryptoTokenOfflineException | CertificateException | IOException | KeyStoreException | NoSuchAlgorithmException | UnrecoverableKeyException | OperatorCreationException ex ) {
485+ } catch (InvalidAlgorithmParameterException | org . cesecore .keys .token .CryptoTokenOfflineException | CertificateException | IOException | KeyStoreException | NoSuchAlgorithmException | UnrecoverableKeyException | OperatorCreationException ex ) {
486486 LOG .error (ex , ex );
487487 throw new CryptoTokenOfflineException (ex );
488488 }
@@ -533,7 +533,7 @@ private void generateSecretKey(String keyAlgorithm, String keySpec, String alias
533533 }
534534 try {
535535 delegate .generateKey (keyAlgorithm , Integer .valueOf (keySpec ), alias );
536- } catch (IllegalArgumentException | NoSuchAlgorithmException | NoSuchProviderException | KeyStoreException | com . keyfactor . util .keys .token .CryptoTokenOfflineException ex ) {
536+ } catch (IllegalArgumentException | NoSuchAlgorithmException | NoSuchProviderException | KeyStoreException | org . cesecore .keys .token .CryptoTokenOfflineException ex ) {
537537 LOG .error (ex , ex );
538538 throw new CryptoTokenOfflineException (ex );
539539 }
@@ -639,7 +639,7 @@ public KeyStorePKCS11CryptoToken() throws InstantiationException {
639639 public KeyStore getActivatedKeyStore () throws CryptoTokenOfflineException {
640640 try {
641641 return getKeyStore ().getKeyStore (); // TODO: Consider if we should instead use the CachingKeystoreWrapper
642- } catch (com . keyfactor . util .keys .token .CryptoTokenOfflineException ex ) {
642+ } catch (org . cesecore .keys .token .CryptoTokenOfflineException ex ) {
643643 throw new CryptoTokenOfflineException (ex );
644644 }
645645 }
0 commit comments