#[non_exhaustive]pub enum ResponseRecord {
Bool {
value: bool,
},
Text {
value: String,
},
SecretRedacted {},
Acknowledged,
}Expand description
Serializable, redacted form of a user response.
Used inside StepFact::PromptAnswered so that the transcript records
what was answered without ever persisting plaintext secrets. The
in-flight Response type lives next to the channel protocol in
rite-runtime; conversion happens at the moment the prompt is accepted.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Bool
Yes / no answer.
Text
Free-form text answer.
SecretRedacted
Secret answer. The plaintext is never stored, and no digest of it is
kept either: a hash of a low-entropy secret (such as a 6-8 digit PIV
PIN) is brute-forceable from a shared transcript. The position of the
enclosing PromptAnswered fact in the chain already records that a
secret was entered at this point.
Acknowledged
Acknowledgement of a Prompt::Continue.
Trait Implementations§
Source§impl Clone for ResponseRecord
impl Clone for ResponseRecord
Source§impl Debug for ResponseRecord
impl Debug for ResponseRecord
Source§impl<'de> Deserialize<'de> for ResponseRecord
impl<'de> Deserialize<'de> for ResponseRecord
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ResponseRecord
impl RefUnwindSafe for ResponseRecord
impl Send for ResponseRecord
impl Sync for ResponseRecord
impl Unpin for ResponseRecord
impl UnsafeUnpin for ResponseRecord
impl UnwindSafe for ResponseRecord
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more