Skip to main content

SecurityApi

Trait SecurityApi 

Source
pub trait SecurityApi {
    // Required methods
    fn automated_security_fixes(
        &self,
        repository: &RepoRef,
    ) -> impl Future<Output = Result<Option<bool>, ForgeError>> + Send;
    fn code_scanning_default_setup(
        &self,
        repository: &RepoRef,
    ) -> impl Future<Output = Result<Option<CodeScanning>, ForgeError>> + Send;
    fn patch_code_scanning_default_setup(
        &self,
        repository: &RepoRef,
        patch: &CodeScanningPatch,
    ) -> impl Future<Output = Result<(), ForgeError>> + Send;
    fn patch_security_analysis(
        &self,
        repository: &RepoRef,
        patch: &AnalysisPatch,
    ) -> impl Future<Output = Result<(), ForgeError>> + Send;
    fn private_vulnerability_reporting(
        &self,
        repository: &RepoRef,
    ) -> impl Future<Output = Result<Option<bool>, ForgeError>> + Send;
    fn set_automated_security_fixes(
        &self,
        repository: &RepoRef,
        enabled: bool,
    ) -> impl Future<Output = Result<(), ForgeError>> + Send;
    fn set_private_vulnerability_reporting(
        &self,
        repository: &RepoRef,
        enabled: bool,
    ) -> impl Future<Output = Result<(), ForgeError>> + Send;
    fn set_vulnerability_alerts(
        &self,
        repository: &RepoRef,
        enabled: bool,
    ) -> impl Future<Output = Result<(), ForgeError>> + Send;
    fn vulnerability_alerts(
        &self,
        repository: &RepoRef,
    ) -> impl Future<Output = Result<Option<bool>, ForgeError>> + Send;
}
Expand description

The security operations of the GitHub API.

Required Methods§

Source

fn automated_security_fixes( &self, repository: &RepoRef, ) -> impl Future<Output = Result<Option<bool>, ForgeError>> + Send

Read whether Dependabot security updates are on. None means GitHub does not answer.

Source

fn code_scanning_default_setup( &self, repository: &RepoRef, ) -> impl Future<Output = Result<Option<CodeScanning>, ForgeError>> + Send

Read the code scanning default setup. None means GitHub does not answer.

Source

fn patch_code_scanning_default_setup( &self, repository: &RepoRef, patch: &CodeScanningPatch, ) -> impl Future<Output = Result<(), ForgeError>> + Send

Write only the changed code scanning default setup properties.

Source

fn patch_security_analysis( &self, repository: &RepoRef, patch: &AnalysisPatch, ) -> impl Future<Output = Result<(), ForgeError>> + Send

Write only the changed security_and_analysis properties.

Source

fn private_vulnerability_reporting( &self, repository: &RepoRef, ) -> impl Future<Output = Result<Option<bool>, ForgeError>> + Send

Read whether private vulnerability reporting is on. None means GitHub does not answer.

Source

fn set_automated_security_fixes( &self, repository: &RepoRef, enabled: bool, ) -> impl Future<Output = Result<(), ForgeError>> + Send

Turn Dependabot security updates on or off.

Source

fn set_private_vulnerability_reporting( &self, repository: &RepoRef, enabled: bool, ) -> impl Future<Output = Result<(), ForgeError>> + Send

Turn private vulnerability reporting on or off.

Source

fn set_vulnerability_alerts( &self, repository: &RepoRef, enabled: bool, ) -> impl Future<Output = Result<(), ForgeError>> + Send

Turn Dependabot alerts on or off.

Source

fn vulnerability_alerts( &self, repository: &RepoRef, ) -> impl Future<Output = Result<Option<bool>, ForgeError>> + Send

Read whether Dependabot alerts are on. None means GitHub does not answer.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§