pub trait SecretProvider: Send + Sync {
// Required methods
fn get_private_key<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<PrivateKey, SecretError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_app_id<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<GitHubAppId, SecretError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_webhook_secret<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<String, SecretError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn cache_duration(&self) -> Duration;
}Expand description
Interface for retrieving GitHub App secrets from secure storage.
Required Methods§
Sourcefn get_private_key<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<PrivateKey, SecretError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_private_key<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<PrivateKey, SecretError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get private key for JWT signing.
Sourcefn get_app_id<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<GitHubAppId, SecretError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_app_id<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<GitHubAppId, SecretError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get GitHub App ID.
Sourcefn get_webhook_secret<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<String, SecretError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_webhook_secret<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<String, SecretError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get webhook secret for signature validation.
Sourcefn cache_duration(&self) -> Duration
fn cache_duration(&self) -> Duration
Get cache duration for secrets.