private ByteSource getSecretSalt(HashRequest request) {
            Optional<Object> secretSalt = Optional.ofNullable(request.getParameters().get(Parameters.PARAMETER_SECRET_SALT));

            return secretSalt
                    .map(salt -> (String) salt)
                    .map(salt -> Base64.getDecoder().decode(salt))
                    .map(SimpleByteSource::new)
                    .orElse(null);
        }
Returns the public salt that should be used to compute a hash based on the specified request.
<p/>
This implementation functions as follows:
<ol>
  <li>If the request salt is not null and non-empty, this will be used, return it.</li>
  <li>If the request salt is null or empty:
    <ol><li>create a new 16-byte salt.</li></ol>
  </li>
</ol>

@param request request the request to process
@return the public salt that should be used to compute a hash based on the specified request or
{@code null} if no public salt should be used.
crypto/hash/src/main/java/org/apache/shiro/crypto/hash/SimpleHashProvider.java