Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add tls support and auth check with access token in grpc server #48

Closed

Conversation

vovkman
Copy link
Contributor

@vovkman vovkman commented May 22, 2024

feat: Add tls support and auth check with access token in grpc server

.tls_config(ServerTlsConfig::new().identity(Identity::from_pem(cert, key)))
.map_err(|e| GeyserPluginError::Custom(e.into()))?;
}
let svc = InterceptedService::new(svc, AccessTokenChecker::new(access_token));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you conditionally make it an intercepted service if token is present?

}

impl AccessTokenChecker {
fn new(access_token: Option<String>) -> Self {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can remove optional if make the above change

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants