class SecurityDataService {

    public Optional<String> decryptId(String encryptedId) {
        if (!encryptedId.contains(SEPARATOR)) {
            log.info("ID: [{}]. Couldn't decrypt, because id does not contain separator [{}]", encryptedId, SEPARATOR);
            return Optional.empty();
        }

        Optional<String> decryptedId = decryptCompositeId(encryptedId)
                                           .map(cmst -> cmst.split(SEPARATOR)[0]);

        if (decryptedId.isEmpty()) {
            log.info("ID: [{}]. Couldn't decrypt ID", encryptedId);
        }

        return decryptedId;
    }

    @Autowired public  SecurityDataService(Environment environment, CryptoProviderHolder cryptoProviderHolder);

}