Skip to main content

DenyRuleConfig

Trait DenyRuleConfig 

Source
pub trait DenyRuleConfig: Send + Sync {
    // Required methods
    fn is_address_denied(&self, address: &Address) -> bool;
    fn is_object_denied(&self, id: &ObjectId) -> bool;
    fn is_package_denied(&self, id: &ObjectId) -> bool;
    fn has_denied_addresses(&self) -> bool;
    fn has_denied_objects(&self) -> bool;
    fn has_denied_packages(&self) -> bool;
    fn package_publish_disabled(&self) -> bool;
    fn package_upgrade_disabled(&self) -> bool;
    fn shared_object_disabled(&self) -> bool;
    fn user_transaction_disabled(&self) -> bool;
    fn receiving_objects_disabled(&self) -> bool;
    fn move_authenticator_disabled(&self) -> bool;
}
Expand description

Read access to a set of transaction deny rules.

Implemented by both a validator’s local TransactionDenyConfig and the consensus-governed DenyRuleSet, so the deny checks can run against either source without knowing which one is in effect.

Required Methods§

Source

fn is_address_denied(&self, address: &Address) -> bool

Whether address is denied as a transaction sender or gas sponsor.

Source

fn is_object_denied(&self, id: &ObjectId) -> bool

Whether the object id is denied as an input or receiving object.

Source

fn is_package_denied(&self, id: &ObjectId) -> bool

Whether the package id is denied as a (transitive) dependency.

Source

fn has_denied_addresses(&self) -> bool

Whether any address is denied; lets checks skip scanning signers when there are none.

Source

fn has_denied_objects(&self) -> bool

Whether any object is denied; lets checks skip scanning input and receiving objects when there are none.

Source

fn has_denied_packages(&self) -> bool

Whether any package is denied; lets checks skip resolving package dependencies (which loads packages from the store) when there are none.

Source

fn package_publish_disabled(&self) -> bool

Source

fn package_upgrade_disabled(&self) -> bool

Source

fn shared_object_disabled(&self) -> bool

Source

fn user_transaction_disabled(&self) -> bool

Source

fn receiving_objects_disabled(&self) -> bool

Source

fn move_authenticator_disabled(&self) -> bool

Implementors§