private void initialize ( ) { createKeysIfNotExist ( ) ; if ( keyPair == null ) { try { loadKeyPair ( ) ; } catch ( IOException | NoSuchAlgorithmException | InvalidKeySpecException e ) { LOGGER . error ( "An error occurred loading key pair" ) ; LOGGER . error ( e . getMessage ( ) ) ; } } if ( secretKey == null ) { try { loadSecretKey ( ) ; } catch ( IOException | ClassNotFoundException e ) { LOGGER . error ( "An error occurred loading secret key" ) ; LOGGER . error ( e . getMessage ( ) ) ; } } }
Initializes the KeyManager