Skip to content

Commit

Permalink
API for the HTTP Basic Auth filter
Browse files Browse the repository at this point in the history
Signed-off-by: huabing zhao <[email protected]>
  • Loading branch information
zhaohuabing committed Oct 11, 2023
1 parent 7d9dd00 commit 947f186
Show file tree
Hide file tree
Showing 4 changed files with 60 additions and 0 deletions.
12 changes: 12 additions & 0 deletions api/envoy/extensions/filters/http/basic_auth/v3/BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# DO NOT EDIT. This file is generated by tools/proto_format/proto_sync.py.

load("@envoy_api//bazel:api_build_system.bzl", "api_proto_package")

licenses(["notice"]) # Apache 2

api_proto_package(
deps = [
"//envoy/config/core/v3:pkg",
"@com_github_cncf_udpa//udpa/annotations:pkg",
],
)
40 changes: 40 additions & 0 deletions api/envoy/extensions/filters/http/basic_auth/v3/basic_auth.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
syntax = "proto3";

package envoy.extensions.filters.http.basic_auth.v3;

import "envoy/config/core/v3/base.proto";

import "xds/annotations/v3/status.proto";

import "udpa/annotations/status.proto";
import "validate/validate.proto";

option java_package = "io.envoyproxy.envoy.extensions.filters.http.basic_auth.v3";
option java_outer_classname = "BasicAuthProto";
option java_multiple_files = true;
option go_package = "github.com/envoyproxy/go-control-plane/envoy/extensions/filters/http/basic_auth/v3;basic_authv3";
option (udpa.annotations.file_status).package_version_status = ACTIVE;
option (xds.annotations.v3.file_status).work_in_progress = true;

// [#protodoc-title: Basic Auth]
// [#not-implemented-hide:]
// Basic Auth :ref:`configuration overview <config_http_filters_basic_auth>`.
// [#extension: envoy.filters.http.basic_auth]

// Basic HTTP authentication.
//
// Example:
//
// .. code-block:: yaml
//
// htpasswd:
// inline_string: |-
// user1:hashed_user1_password
// user2:hashed_user2_password
//
message BasicAuth {
// Username-password pairs used to verify user credentials in the "Authorization" header.
// The value needs to be the htpasswd format.
// Reference to https://httpd.apache.org/docs/2.4/programs/htpasswd.html
config.core.v3.DataSource htpasswd = 1 [(udpa.annotations.sensitive) = true];
}
7 changes: 7 additions & 0 deletions source/extensions/extensions_metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,13 @@ envoy.filters.http.bandwidth_limit:
status: stable
type_urls:
- envoy.extensions.filters.http.bandwidth_limit.v3.BandwidthLimit
envoy.filters.http.basic_auth:
categories:
- envoy.filters.http
security_posture: unknown
status: wip
type_urls:
- envoy.extensions.filters.http.basic_auth.v3.BasicAuth
envoy.filters.http.buffer:
categories:
- envoy.filters.http
Expand Down
1 change: 1 addition & 0 deletions tools/spelling/spelling_dictionary.txt
Original file line number Diff line number Diff line change
Expand Up @@ -816,6 +816,7 @@ hostnames
hostset
hotrestart
hrefs
htpasswd
huffman
hystrix
idempotency
Expand Down

0 comments on commit 947f186

Please sign in to comment.