- Sort Score
- Result 10 results
- Languages All
Results 111 - 120 of 1,756 for securityv1 (0.15 sec)
-
tests/test_security_openid_connect.py
from fastapi import Depends, FastAPI, Security from fastapi.security.open_id_connect_url import OpenIdConnect from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() oid = OpenIdConnect(openIdConnectUrl="/openid") class User(BaseModel): username: str def get_current_user(oauth_header: str = Security(oid)): user = User(username=oauth_header) return user
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.2K bytes - Viewed (0) -
security/pkg/credentialfetcher/fetcher_test.go
}{ "gce test": { fetcherType: security.GCE, trustdomain: "abc.svc.id.goog", jwtPath: "/var/run/secrets/tokens/istio-token", identityProvider: security.GCE, expectedErr: "", // No error when ID token auth is enabled. expectedToken: "", expectedIdp: "GoogleComputeEngine", }, "mock test": { fetcherType: security.Mock, trustdomain: "",
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Fri Feb 03 20:21:32 UTC 2023 - 3K bytes - Viewed (0) -
tests/test_security_api_key_header.py
from fastapi import Depends, FastAPI, Security from fastapi.security import APIKeyHeader from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() api_key = APIKeyHeader(name="key") class User(BaseModel): username: str def get_current_user(oauth_header: str = Security(api_key)): user = User(username=oauth_header) return user @app.get("/users/me")
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 1.8K bytes - Viewed (0) -
security/pkg/nodeagent/sds/sdsservice.go
close(s.stop) } // toEnvoySecret converts a security.SecretItem to an Envoy tls.Secret func toEnvoySecret(s *security.SecretItem, caRootPath string, pkpConf *mesh.PrivateKeyProvider) *tls.Secret { secret := &tls.Secret{ Name: s.ResourceName, } var cfg security.SdsCertificateConfig ok := false if s.ResourceName == security.FileRootSystemCACert { cfg, ok = security.SdsCertificateConfigFromResourceNameForOSCACert(caRootPath)
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Sat May 25 00:20:04 UTC 2024 - 10.9K bytes - Viewed (0) -
pkg/config/security/security_test.go
expected: security.JwksInfo{ Hostname: "foo.bar.com", Scheme: "http", Port: 1234, UseSSL: false, }, }, { in: "https://foo.bar.com:1234/secure/key", expected: security.JwksInfo{ Hostname: "foo.bar.com", Scheme: "https", Port: 1234, UseSSL: true, }, }, } for _, c := range cases { actual, err := security.ParseJwksURI(c.in)
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Sat Apr 20 01:58:53 UTC 2024 - 8.3K bytes - Viewed (0) -
tests/test_security_api_key_header_description.py
from fastapi import Depends, FastAPI, Security from fastapi.security import APIKeyHeader from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() api_key = APIKeyHeader(name="key", description="An API Key Header") class User(BaseModel): username: str def get_current_user(oauth_header: str = Security(api_key)): user = User(username=oauth_header) return user
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2K bytes - Viewed (0) -
docs/em/docs/tutorial/security/simple-oauth2.md
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Thu Apr 18 19:53:19 UTC 2024 - 8.9K bytes - Viewed (0) -
docs_src/security/tutorial007_an.py
import secrets from fastapi import Depends, FastAPI, HTTPException, status from fastapi.security import HTTPBasic, HTTPBasicCredentials from typing_extensions import Annotated app = FastAPI() security = HTTPBasic() def get_current_username( credentials: Annotated[HTTPBasicCredentials, Depends(security)], ): current_username_bytes = credentials.username.encode("utf8") correct_username_bytes = b"stanleyjobson"
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Tue Mar 26 16:56:53 UTC 2024 - 1.2K bytes - Viewed (0) -
tests/test_security_openid_connect_optional.py
from fastapi import Depends, FastAPI, Security from fastapi.security.open_id_connect_url import OpenIdConnect from fastapi.testclient import TestClient from pydantic import BaseModel app = FastAPI() oid = OpenIdConnect(openIdConnectUrl="/openid", auto_error=False) class User(BaseModel): username: str def get_current_user(oauth_header: Optional[str] = Security(oid)): if oauth_header is None:
Registered: Mon Jun 17 08:32:26 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 2.4K bytes - Viewed (0) -
tests/fuzz/security_fuzzer.go
"google.golang.org/grpc/credentials" "google.golang.org/grpc/peer" pb "istio.io/api/security/v1alpha1" "istio.io/istio/pkg/security" mockca "istio.io/istio/security/pkg/pki/ca/mock" "istio.io/istio/security/pkg/pki/util" "istio.io/istio/security/pkg/server/ca" "istio.io/istio/security/pkg/server/ca/authenticate" ) func FuzzGenCSR(data []byte) int { f := fuzz.NewConsumer(data)
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed Feb 28 16:41:38 UTC 2024 - 3.2K bytes - Viewed (0)