Search in sources :

Example 1 with TicketGrantingCookieCipherExecutor

use of org.apereo.cas.util.cipher.TicketGrantingCookieCipherExecutor in project cas by apereo.

the class TicketGrantingCookieCipherExecutorTests method checkEncryptionWithDefaultSettings.

@Test
public void checkEncryptionWithDefaultSettings() {
    final CipherExecutor cipherExecutor = new TicketGrantingCookieCipherExecutor("1PbwSbnHeinpkZOSZjuSJ8yYpUrInm5aaV18J2Ar4rM", "szxK-5_eJjs-aUj-64MpUZ-GPPzGLhYPLGl0wrYjYNVAGva2P0lLe6UGKGM7k8dWxsOVGutZWgvmY3l5oVPO3w");
    assertEquals(cipherExecutor.decode(cipherExecutor.encode("CAS Test")), "CAS Test");
}
Also used : TicketGrantingCookieCipherExecutor(org.apereo.cas.util.cipher.TicketGrantingCookieCipherExecutor) BaseStringCipherExecutor(org.apereo.cas.util.cipher.BaseStringCipherExecutor) CipherExecutor(org.apereo.cas.CipherExecutor) TicketGrantingCookieCipherExecutor(org.apereo.cas.util.cipher.TicketGrantingCookieCipherExecutor) Test(org.junit.Test)

Aggregations

CipherExecutor (org.apereo.cas.CipherExecutor)1 BaseStringCipherExecutor (org.apereo.cas.util.cipher.BaseStringCipherExecutor)1 TicketGrantingCookieCipherExecutor (org.apereo.cas.util.cipher.TicketGrantingCookieCipherExecutor)1 Test (org.junit.Test)1