pub struct RexUpdateResult {
pub rex_id: RexId,
pub target_timestamp: TimestampMs,
pub response_hash: [u8; 32],
pub input_commitment: InputCommitmentBytes,
pub signature: SignatureBytes,
pub rex_result: Vec<u8>,
pub attestation_report: Option<AttestationReport>,
pub authority_key: AuthorityKeyBytes,
}Expand description
A structure representing the result of an REX update This structure is designed to fit within Solana’s transaction size limit TODO: https://linear.app/subzero-labs/issue/SUB-449/audit-transaction-sizes-in-the-REX-subsystem
Fields§
§rex_id: RexIdThe identifier of the REX (should be kept under 100 bytes)
target_timestamp: TimestampMsThe round in which this result should be proposed
response_hash: [u8; 32]Blake3 hash of rex_result (32 bytes)
input_commitment: InputCommitmentBytesBlake3 hash commitment of the original request input bytes (32 bytes) This is included in the signature transcript to bind the response to the exact request payload observed by the REX service.
signature: SignatureBytesSignature of the hash of the REX response, base64 encoded.
rex_result: Vec<u8>Response data (up to MAX_TRANSACTION_SIZE bytes in size)
attestation_report: Option<AttestationReport>Optional attestation report, if available This can be used to provide additional context or verification of the REX result.
Validator’s protocol public key bytes of the validator that executed the edge rquest.
Implementations§
Source§impl RexUpdateResult
impl RexUpdateResult
Sourcepub fn new(
rex_id: RexId,
target_timestamp: TimestampMs,
rex_result: Vec<u8>,
input_commitment: InputCommitmentBytes,
signature: SignatureBytes,
attestation_report: Option<AttestationReport>,
authority_key: AuthorityKeyBytes,
) -> Result<Self, &'static str>
pub fn new( rex_id: RexId, target_timestamp: TimestampMs, rex_result: Vec<u8>, input_commitment: InputCommitmentBytes, signature: SignatureBytes, attestation_report: Option<AttestationReport>, authority_key: AuthorityKeyBytes, ) -> Result<Self, &'static str>
Create a RexUpdateResult
Trait Implementations§
Source§impl Clone for RexUpdateResult
impl Clone for RexUpdateResult
Source§fn clone(&self) -> RexUpdateResult
fn clone(&self) -> RexUpdateResult
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RexUpdateResult
impl Debug for RexUpdateResult
Source§impl Default for RexUpdateResult
impl Default for RexUpdateResult
Source§impl<'de> Deserialize<'de> for RexUpdateResult
impl<'de> Deserialize<'de> for RexUpdateResult
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>,
impl Eq for RexUpdateResult
Source§impl PartialEq for RexUpdateResult
impl PartialEq for RexUpdateResult
Source§fn eq(&self, other: &RexUpdateResult) -> bool
fn eq(&self, other: &RexUpdateResult) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for RexUpdateResult
impl Serialize for RexUpdateResult
impl StructuralPartialEq for RexUpdateResult
Auto Trait Implementations§
impl Freeze for RexUpdateResult
impl RefUnwindSafe for RexUpdateResult
impl Send for RexUpdateResult
impl Sync for RexUpdateResult
impl Unpin for RexUpdateResult
impl UnsafeUnpin for RexUpdateResult
impl UnwindSafe for RexUpdateResult
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.