Require non-null proofs in "confirm username hash" requests

This commit is contained in:
Jon Chambers
2024-02-26 10:30:52 -05:00
committed by GitHub
parent 6fd0cba06a
commit d018efe2a5
2 changed files with 27 additions and 0 deletions

View File

@@ -7,6 +7,7 @@ package org.whispersystems.textsecuregcm.entities;
import javax.annotation.Nullable;
import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
@@ -25,6 +26,7 @@ public record ConfirmUsernameHashRequest(
@JsonSerialize(using = ByteArrayBase64UrlAdapter.Serializing.class)
@JsonDeserialize(using = ByteArrayBase64UrlAdapter.Deserializing.class)
@NotNull
byte[] zkProof,
@Schema(type = "string", description = "The url-safe base64-encoded encrypted username to be stored for username links")