pub enum ComplianceRequest {
EvalPolicies {
source_policies: HashMap<String, HashMap<Resource, Policy>>,
destination: Resource,
},
GetPolicy(Resource),
GetPolicies(HashSet<Resource>),
SetPolicy {
resource: Resource,
policy: Policy,
},
SetConfidentiality {
resource: Resource,
confidentiality: ConfidentialityPolicy,
},
SetIntegrity {
resource: Resource,
integrity: u32,
},
SetDeleted(Resource),
SetConsent {
resource: Resource,
consent: bool,
},
}
Expand description
Compliance service request types.
Internal API for the compliance service, which manages policies, evaluates authorization decisions, and enforces organizational and regulatory requirements for data flows.
Variants§
EvalPolicies
Evaluate whether a proposed data flow complies with all applicable policies.
Compares source resource policies against destination requirements to determine if the flow should be authorized. Considers confidentiality, integrity, consent, and other policy constraints.
Fields
GetPolicy(Resource)
Retrieve the current compliance policy for a specific resource.
Returns the complete policy configuration including confidentiality, integrity, consent, and deletion status for the requested resource.
GetPolicies(HashSet<Resource>)
Retrieve current compliance policies for multiple resources.
Batch operation to efficiently query policy configurations for multiple resources in a single request.
SetPolicy
Set a complete compliance policy for a specific resource.
Replaces the existing policy with new configuration that defines all aspects of compliance requirements for the resource.
Fields
SetConfidentiality
Update confidentiality requirements for a specific resource.
Modifies only the confidentiality aspects of the resource’s policy while preserving other policy components.
Fields
confidentiality: ConfidentialityPolicy
New confidentiality policy requirements
SetIntegrity
Update integrity level requirements for a specific resource.
Sets the minimum integrity level required for operations involving this resource, typically on a numerical scale.
SetDeleted(Resource)
Mark a resource as deleted for compliance tracking.
Updates the resource’s policy to reflect its deletion status while maintaining historical records for audit purposes.
SetConsent
Update consent status for data processing operations on a resource.
Sets or revokes consent for operations that require explicit permission, typically for privacy and regulatory compliance.
Trait Implementations§
Source§impl Clone for ComplianceRequest
impl Clone for ComplianceRequest
Source§fn clone(&self) -> ComplianceRequest
fn clone(&self) -> ComplianceRequest
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for ComplianceRequest
impl Debug for ComplianceRequest
Source§impl Service<ComplianceRequest> for ComplianceService<ConsentService>
impl Service<ComplianceRequest> for ComplianceService<ConsentService>
Source§type Response = ComplianceResponse
type Response = ComplianceResponse
Source§type Error = TraceabilityError
type Error = TraceabilityError
Source§type Future = Pin<Box<dyn Future<Output = Result<<ComplianceService as Service<ComplianceRequest>>::Response, <ComplianceService as Service<ComplianceRequest>>::Error>> + Send>>
type Future = Pin<Box<dyn Future<Output = Result<<ComplianceService as Service<ComplianceRequest>>::Response, <ComplianceService as Service<ComplianceRequest>>::Error>> + Send>>
Source§fn poll_ready(&mut self, _: &mut Context<'_>) -> Poll<Result<(), Self::Error>>
fn poll_ready(&mut self, _: &mut Context<'_>) -> Poll<Result<(), Self::Error>>
Poll::Ready(Ok(()))
when the service is able to process requests. Read moreSource§fn call(&mut self, request: ComplianceRequest) -> Self::Future
fn call(&mut self, request: ComplianceRequest) -> Self::Future
Auto Trait Implementations§
impl Freeze for ComplianceRequest
impl RefUnwindSafe for ComplianceRequest
impl Send for ComplianceRequest
impl Sync for ComplianceRequest
impl Unpin for ComplianceRequest
impl UnwindSafe for ComplianceRequest
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> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request
§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered
].