pull/35502/head
Craig Tiller 1 year ago
parent 20e5b2c4bb
commit 17da58ad37
  1. 2
      src/core/lib/security/authorization/grpc_server_authz_filter.cc
  2. 2
      src/core/lib/security/authorization/grpc_server_authz_filter.h
  3. 3
      src/core/lib/surface/init.cc

@ -118,7 +118,7 @@ absl::Status GrpcServerAuthzFilter::Call::OnClientInitialMetadata(
return absl::OkStatus(); return absl::OkStatus();
} }
const grpc_channel_filter GrpcServerAuthzFilter::kFilterVtable = const grpc_channel_filter GrpcServerAuthzFilter::kFilter =
MakePromiseBasedFilter<GrpcServerAuthzFilter, FilterEndpoint::kServer>( MakePromiseBasedFilter<GrpcServerAuthzFilter, FilterEndpoint::kServer>(
"grpc-server-authz"); "grpc-server-authz");

@ -37,7 +37,7 @@ namespace grpc_core {
class GrpcServerAuthzFilter final class GrpcServerAuthzFilter final
: public ImplementChannelFilter<GrpcServerAuthzFilter> { : public ImplementChannelFilter<GrpcServerAuthzFilter> {
public: public:
static const grpc_channel_filter kFilterVtable; static const grpc_channel_filter kFilter;
static absl::StatusOr<GrpcServerAuthzFilter> Create(const ChannelArgs& args, static absl::StatusOr<GrpcServerAuthzFilter> Create(const ChannelArgs& args,
ChannelFilter::Args); ChannelFilter::Args);

@ -82,8 +82,7 @@ void RegisterSecurityFilters(CoreConfiguration::Builder* builder) {
.IfHasChannelArg(GRPC_SERVER_CREDENTIALS_ARG); .IfHasChannelArg(GRPC_SERVER_CREDENTIALS_ARG);
} }
builder->channel_init() builder->channel_init()
->RegisterFilter(GRPC_SERVER_CHANNEL, ->RegisterFilter<GrpcServerAuthzFilter>(GRPC_SERVER_CHANNEL)
&GrpcServerAuthzFilter::kFilterVtable)
.IfHasChannelArg(GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER) .IfHasChannelArg(GRPC_ARG_AUTHORIZATION_POLICY_PROVIDER)
.After<ServerAuthFilter>() .After<ServerAuthFilter>()
.After<LegacyServerAuthFilter>(); .After<LegacyServerAuthFilter>();

Loading…
Cancel
Save