aboutsummaryrefslogtreecommitdiffstats
path: root/odl-aaa-moon/aaa/aaa-authn-mdsal-store/aaa-authn-mdsal-store-impl/src/test/java/org/opendaylight/aaa/authn/mdsal/store/DataEncrypterTest.java
diff options
context:
space:
mode:
authorTrevor Bramwell <tbramwell@linuxfoundation.org>2016-09-12 11:06:56 -0700
committerThomas Duval <thomas.duval@orange.com>2016-09-20 10:38:38 +0200
commitba20dff39a897ff8dbd71260c42da923c9bdcf7a (patch)
treec3697f48fad868f74bf3b363dae43519d9045a1b /odl-aaa-moon/aaa/aaa-authn-mdsal-store/aaa-authn-mdsal-store-impl/src/test/java/org/opendaylight/aaa/authn/mdsal/store/DataEncrypterTest.java
parentcdcd1fd6690b69af3a3cf4b430e51e4febec1c9a (diff)
Move ODL-AAA-MOON under 'upstream' Directory
Change-Id: Ie010fbe3899e151421940908dbe8675aade54e2d Signed-off-by: Trevor Bramwell <tbramwell@linuxfoundation.org> (cherry picked from commit cf864337c13b4638c588badf3f589f9e39318c95)
Diffstat (limited to 'odl-aaa-moon/aaa/aaa-authn-mdsal-store/aaa-authn-mdsal-store-impl/src/test/java/org/opendaylight/aaa/authn/mdsal/store/DataEncrypterTest.java')
-rw-r--r--odl-aaa-moon/aaa/aaa-authn-mdsal-store/aaa-authn-mdsal-store-impl/src/test/java/org/opendaylight/aaa/authn/mdsal/store/DataEncrypterTest.java38
1 files changed, 0 insertions, 38 deletions
diff --git a/odl-aaa-moon/aaa/aaa-authn-mdsal-store/aaa-authn-mdsal-store-impl/src/test/java/org/opendaylight/aaa/authn/mdsal/store/DataEncrypterTest.java b/odl-aaa-moon/aaa/aaa-authn-mdsal-store/aaa-authn-mdsal-store-impl/src/test/java/org/opendaylight/aaa/authn/mdsal/store/DataEncrypterTest.java
deleted file mode 100644
index eec69bc0..00000000
--- a/odl-aaa-moon/aaa/aaa-authn-mdsal-store/aaa-authn-mdsal-store-impl/src/test/java/org/opendaylight/aaa/authn/mdsal/store/DataEncrypterTest.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved.
- *
- * This program and the accompanying materials are made available under the
- * terms of the Eclipse Public License v1.0 which accompanies this distribution,
- * and is available at http://www.eclipse.org/legal/epl-v10.html
- */
-
-package org.opendaylight.aaa.authn.mdsal.store;
-
-import static org.junit.Assert.assertEquals;
-
-import javax.xml.bind.DatatypeConverter;
-import org.junit.Test;
-
-public class DataEncrypterTest {
-
- @Test
- public void testEncrypt() {
- DataEncrypter dataEncry = new DataEncrypter("foo_key_test");
- String token = "foo_token_test";
- String eToken = dataEncry.encrypt(token);
- // check for decryption result
- String returnToken = dataEncry.decrypt(eToken);
- String tokenBase64 = DatatypeConverter.printBase64Binary(token.getBytes());
- assertEquals(tokenBase64, returnToken);
- }
-
- @Test
- public void testDecrypt() {
- DataEncrypter dataEncry = new DataEncrypter("foo_key_test");
- String eToken = "foo_etoken_test";
- assertEquals(dataEncry.decrypt(""), null);
- // check for encryption Tag
- assertEquals(eToken, dataEncry.decrypt(eToken));
- }
-
-}