@Override
  public Pair<String, Map<String, String>> parseSignedId(String signedId) throws RestServiceException {
    if (!isIdSigned(signedId)) {
      throw new RestServiceException("Expected ID to be signed: " + signedId, RestServiceErrorCode.InternalServerError);
    }
    try {
      int startIndex = RestUtils.SIGNED_ID_PREFIX.length() + (signedId.startsWith("/") ? 1 : 0);
      String base64String = signedId.substring(startIndex);
      String jsonString = new String(Base64.decodeBase64(base64String), StandardCharsets.UTF_8);
      return SignedIdSerDe.fromJson(jsonString);
    } catch (Exception e) {
      throw new RestServiceException("Error deserializing signed ID", e, RestServiceErrorCode.BadRequest);
    }
  }
Reference implementation for an {@link IdSigningService}.
<p>
<b>Warning:</b> This implementation is not secure or tamper-proof, since it does not actually sign the data that it
is passed. A secure implementation would either need to use an authenticated encryption scheme or attach a signature.
ambry-frontend/src/main/java/com/github/ambry/frontend/AmbryIdSigningService.java