class JamesSignatureHandler implements SignatureHandler {

    @Override
    public String sign(String source) {
        Preconditions.checkNotNull(source);
        try {
            Signature javaSignature = Signature.getInstance(ALGORITHM);
            javaSignature.initSign(securityKeys.getPrivateKey());
            javaSignature.update(source.getBytes());
            return Base64.getEncoder().encodeToString(javaSignature.sign());
        } catch (NoSuchAlgorithmException | InvalidKeyException | SignatureException e) {
            throw new RuntimeException(e);
        }
    }

    @Inject @VisibleForTesting  JamesSignatureHandler(SecurityKeyLoader keyLoader);

}