</exclusion>
</exclusions>
</dependency>
- <dependency>
- <groupId>org.apache.httpcomponents</groupId>
- <artifactId>httpclient</artifactId>
- </dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
import com.att.eelf.configuration.EELFLogger;
import com.att.eelf.configuration.EELFManager;
+import java.util.Base64;
import javax.crypto.Cipher;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
-import org.apache.commons.codec.binary.Base64;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.env.Environment;
import org.springframework.stereotype.Component;
Cipher cipher = Cipher.getInstance(transformation);
cipher.init(Cipher.ENCRYPT_MODE, skeySpec, iv);
byte[] encrypted = cipher.doFinal(value.getBytes());
- return Base64.encodeBase64String(encrypted);
+ return Base64.getEncoder().encodeToString(encrypted);
} catch (Exception ex) {
errors.error("Unexpected exception {0}", ex.getMessage());
debug.debug("Unexpected exception", ex);
SecretKeySpec skeySpec = new SecretKeySpec(key.getBytes("UTF-8"), "AES");
Cipher cipher = Cipher.getInstance(transformation);
cipher.init(Cipher.DECRYPT_MODE, skeySpec, iv);
- byte[] original = cipher.doFinal(Base64.decodeBase64(encrypted));
+ byte[] original = cipher.doFinal(Base64.getDecoder().decode(encrypted));
return new String(original);
} catch (Exception ex) {
errors.error("Unexpected exception {0}", ex.getMessage());
</exclusion>\r
</exclusions>\r
</dependency>\r
- <dependency>\r
- <groupId>org.apache.httpcomponents</groupId>\r
- <artifactId>httpclient</artifactId>\r
- </dependency>\r
<dependency>\r
<groupId>org.springframework</groupId>\r
<artifactId>spring-test</artifactId>\r
\r
import com.att.eelf.configuration.EELFLogger;\r
import com.att.eelf.configuration.EELFManager;\r
+import java.util.Base64;\r
import javax.crypto.Cipher;\r
import javax.crypto.spec.IvParameterSpec;\r
import javax.crypto.spec.SecretKeySpec;\r
-import org.apache.commons.codec.binary.Base64;\r
import org.springframework.beans.factory.annotation.Autowired;\r
import org.springframework.core.env.Environment;\r
import org.springframework.stereotype.Component;\r
Cipher cipher = Cipher.getInstance(transformation);\r
cipher.init(Cipher.ENCRYPT_MODE, skeySpec, iv);\r
byte[] encrypted = cipher.doFinal(value.getBytes());\r
- return Base64.encodeBase64String(encrypted);\r
+ return Base64.getEncoder().encodeToString(encrypted);\r
} catch (Exception ex) {\r
errors.error("Unexpected exception {0}", ex.getMessage());\r
debug.debug("Unexpected exception", ex);\r
SecretKeySpec skeySpec = new SecretKeySpec(key.getBytes("UTF-8"), "AES");\r
Cipher cipher = Cipher.getInstance(transformation);\r
cipher.init(Cipher.DECRYPT_MODE, skeySpec, iv);\r
- byte[] original = cipher.doFinal(Base64.decodeBase64(encrypted));\r
+ byte[] original = cipher.doFinal(Base64.getDecoder().decode(encrypted));\r
return new String(original);\r
} catch (Exception ex) {\r
errors.error("Unexpected exception {0}", ex.getMessage());\r
</dependency>
<!-- <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-loader-tools</artifactId>
</dependency> -->
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-data-jpa</artifactId>
- </dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>
- <dependency>
- <groupId>org.apache.httpcomponents</groupId>
- <artifactId>httpclient</artifactId>
- </dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
import com.att.eelf.configuration.EELFLogger;
import com.att.eelf.configuration.EELFManager;
+import java.util.Base64;
import javax.crypto.Cipher;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
-import org.apache.commons.codec.binary.Base64;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.env.Environment;
import org.springframework.stereotype.Component;
Cipher cipher = Cipher.getInstance(transformation);
cipher.init(Cipher.ENCRYPT_MODE, skeySpec, iv);
byte[] encrypted = cipher.doFinal(value.getBytes());
- return Base64.encodeBase64String(encrypted);
+ return Base64.getEncoder().encodeToString(encrypted);
} catch (Exception ex) {
errors.error("Unexpected exception {0}", ex.getMessage());
debug.debug("Unexpected exception", ex);
SecretKeySpec skeySpec = new SecretKeySpec(key.getBytes("UTF-8"), "AES");
Cipher cipher = Cipher.getInstance(transformation);
cipher.init(Cipher.DECRYPT_MODE, skeySpec, iv);
- byte[] original = cipher.doFinal(Base64.decodeBase64(encrypted));
+ byte[] original = cipher.doFinal(Base64.getDecoder().decode(encrypted));
return new String(original);
} catch (Exception ex) {
errors.error("Unexpected exception {0}", ex.getMessage());
</dependency>
<!-- <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-loader-tools</artifactId>
</dependency> -->
- <dependency>
- <groupId>org.springframework.boot</groupId>
- <artifactId>spring-boot-starter-data-jpa</artifactId>
- </dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>
- <dependency>
- <groupId>org.apache.httpcomponents</groupId>
- <artifactId>httpclient</artifactId>
- </dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
import com.att.eelf.configuration.EELFLogger;
import com.att.eelf.configuration.EELFManager;
+import java.util.Base64;
import javax.crypto.Cipher;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
-import org.apache.commons.codec.binary.Base64;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.env.Environment;
import org.springframework.stereotype.Component;
Cipher cipher = Cipher.getInstance(transformation);
cipher.init(Cipher.ENCRYPT_MODE, skeySpec, iv);
byte[] encrypted = cipher.doFinal(value.getBytes());
- return Base64.encodeBase64String(encrypted);
+ return Base64.getEncoder().encodeToString(encrypted);
} catch (Exception ex) {
errors.error("Unexpected exception {0}", ex.getMessage());
debug.debug("Unexpected exception", ex);
SecretKeySpec skeySpec = new SecretKeySpec(key.getBytes("UTF-8"), "AES");
Cipher cipher = Cipher.getInstance(transformation);
cipher.init(Cipher.DECRYPT_MODE, skeySpec, iv);
- byte[] original = cipher.doFinal(Base64.decodeBase64(encrypted));
+ byte[] original = cipher.doFinal(Base64.getDecoder().decode(encrypted));
return new String(original);
} catch (Exception ex) {
errors.error("Unexpected exception {0}", ex.getMessage());