public class CipherUtilities extends Object
Modifier and Type | Method and Description |
---|---|
protected static long |
generateEncryptionToken(S_LibrarySession session,
Long cid)
Derive an encryption token from the specified content ID.
|
protected static InputStream |
getDecryptedInputStream(S_LibrarySession session,
long token,
InputStream is)
Return an InputStream that wraps the specified InputStream and decrypts its contents.
|
protected static InputStream |
getEncryptedInputStream(S_LibrarySession session,
long token,
InputStream is)
Return an InputStream that wraps the specified InputStream and encrypts its contents.
|
protected static long generateEncryptionToken(S_LibrarySession session, Long cid) throws IfsException
session
- the session contextcid
- the content ID used in storageIfsException
- if the operation failsprotected static InputStream getEncryptedInputStream(S_LibrarySession session, long token, InputStream is) throws IfsException
session
- the session contexttoken
- the encryption tokenis
- the InputStream to wrapIfsException
- if the operation failsprotected static InputStream getDecryptedInputStream(S_LibrarySession session, long token, InputStream is) throws IfsException
session
- the session contexttoken
- the encryption tokenis
- the InputStream to wrapIfsException
- if the operation failsCopyright © 2023. All rights reserved.