org.apache.activemq.artemis.spi.core.security.scram

## Class StringPrep

- java.lang.Object
- - org.apache.activemq.artemis.spi.core.security.scram.StringPrep

-     public class StringPrep
      extends Object

  rfc3454 StringPrep, with an implementation of rfc4013 SASLPrep.

  StringPrep case folding is unimplemented, as it's not required by SASLPrep.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `protected static class` | `StringPrep.CharClass` A representation of sets of character classes.
    `static class` | `StringPrep.StringPrepError` A prohibited string has been passed to StringPrep.
    `static class` | `StringPrep.StringPrepProhibitedCharacter` A prohibited character was detected.
    `static class` | `StringPrep.StringPrepRTLError` RTL verification has failed, according to rfc3454 section 6.
    `static class` | `StringPrep.StringPrepRTLErrorBothRALandL`
    `static class` | `StringPrep.StringPrepRTLErrorRALWithoutPrefix`
    `static class` | `StringPrep.StringPrepRTLErrorRALWithoutSuffix`
    `static class` | `StringPrep.StringPrepUnassignedCodepoint` A prohibited unassigned codepoint was detected.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `StringPrep()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static boolean` | `isContainingProhibitedCharacters(String s)`
    `static String` | `prepAsQueryString(String s)` Apply SASLPrep and return the result.
    `static String` | `prepAsStoredString(String s)` Apply SASLPrep and return the result.
    `protected static void` | `verifyRTL(String s)` Perform RTL verification according to rfc3454 section 6.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### StringPrep

          public StringPrep()

  - ### Method Detail

    - #### verifyRTL

          protected static void verifyRTL(String s)
                                   throws StringPrep.StringPrepRTLError

      Perform RTL verification according to rfc3454 section 6. On failure, throw a subclass of `StringPrep.StringPrepRTLError`.
      Throws:
        `StringPrep.StringPrepRTLError`

    - #### prepAsStoredString

          public static String prepAsStoredString(String s)
                                           throws StringPrep.StringPrepError

      Apply SASLPrep and return the result. is treated as a stored string.
      Throws:
        `StringPrep.StringPrepError`

    - #### prepAsQueryString

          public static String prepAsQueryString(String s)
                                          throws StringPrep.StringPrepError

      Apply SASLPrep and return the result. is treated as a query string.
      Throws:
        `StringPrep.StringPrepError`

    - #### isContainingProhibitedCharacters

          public static boolean isContainingProhibitedCharacters(String s)

Copyright © 2021 The Apache Software Foundation. All rights reserved.