public class ScramStringFormatting extends Object
Constructor and Description |
---|
ScramStringFormatting() |
Modifier and Type | Method and Description |
---|---|
static byte[] |
base64Decode(String value) |
static String |
base64Encode(byte[] value) |
static String |
base64Encode(String value) |
static String |
fromSaslName(String value)
Given a saslName, return a non-escaped String.
|
static String |
toSaslName(String value)
Given a value-safe-char (normalized UTF-8 String),
return one where characters ',' and '=' are represented by '=2C' or '=3D', respectively.
|
public static String toSaslName(String value)
value
- The value to convert so saslNamepublic static String fromSaslName(String value) throws IllegalArgumentException
value
- The saslNameIllegalArgumentException
- If a ',' character is present, or a '=' not followed by either '2C' or '3D'public static String base64Encode(byte[] value) throws IllegalArgumentException
IllegalArgumentException
public static String base64Encode(String value) throws IllegalArgumentException
IllegalArgumentException
public static byte[] base64Decode(String value) throws IllegalArgumentException
IllegalArgumentException
Copyright © 2019–2023. All rights reserved.