Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 1,029 for beaten (0.2 sec)

  1. fastapi/security/http.py

        The first part is the `scheme`, the second part is the `credentials`.
    
        For example, in an HTTP Bearer token scheme, the client will send a header
        like:
    
        ```
        Authorization: Bearer deadbeef12346
        ```
    
        In this case:
    
        * `scheme` will have the value `"Bearer"`
        * `credentials` will have the value `"deadbeef12346"`
        """
    
        scheme: Annotated[
            str,
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Fri Apr 19 15:29:38 UTC 2024
    - 13.2K bytes
    - Viewed (0)
  2. docs/en/docs/tutorial/security/first-steps.md

    !!! info
        A "bearer" token is not the only option.
    
        But it's the best one for our use case.
    
        And it might be the best for most use cases, unless you are an OAuth2 expert and know exactly why there's another option that suits better your needs.
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Mon Jun 03 01:48:20 UTC 2024
    - 9.1K bytes
    - Viewed (0)
  3. docs_src/security/tutorial004_py310.py

                headers={"WWW-Authenticate": "Bearer"},
            )
        access_token_expires = timedelta(minutes=ACCESS_TOKEN_EXPIRE_MINUTES)
        access_token = create_access_token(
            data={"sub": user.username}, expires_delta=access_token_expires
        )
        return Token(access_token=access_token, token_type="bearer")
    
    
    @app.get("/users/me/", response_model=User)
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Mon May 20 17:37:28 UTC 2024
    - 4K bytes
    - Viewed (0)
  4. docs/ru/docs/tutorial/security/first-steps.md

        * Но для этого необходима аутентификация для конкретной конечной точки.
        * Поэтому для аутентификации в нашем API он посылает заголовок `Authorization` со значением `Bearer` плюс сам токен.
        * Если токен содержит `foobar`, то содержание заголовка `Authorization` будет таким: `Bearer foobar`.
    
    ## Класс `OAuth2PasswordBearer` в **FastAPI**
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Wed Mar 13 19:02:19 UTC 2024
    - 15.4K bytes
    - Viewed (0)
  5. docs/de/docs/tutorial/security/first-steps.md

    In diesem Beispiel verwenden wir **OAuth2** mit dem **Password**-Flow und einem **Bearer**-Token. Wir machen das mit der Klasse `OAuth2PasswordBearer`.
    
    !!! info
        Ein „Bearer“-Token ist nicht die einzige Option.
    
        Aber es ist die beste für unseren Anwendungsfall.
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sat Mar 30 18:07:08 UTC 2024
    - 10.3K bytes
    - Viewed (0)
  6. docs/zh/docs/tutorial/security/first-steps.md

        - 为指定的端点(Endpoint)进行身份验证
        - 因此,用 API 验证身份时,要发送值为 `Bearer` + 令牌的请求头 `Authorization`
        - 假如令牌为 `foobar`,`Authorization` 请求头就是: `Bearer foobar`
    
    ## **FastAPI** 的 `OAuth2PasswordBearer`
    
    **FastAPI** 提供了不同抽象级别的安全工具。
    
    本例使用 **OAuth2** 的 **Password** 流以及 **Bearer** 令牌(`Token`)。为此要使用 `OAuth2PasswordBearer` 类。
    
    !!! info "说明"
    
        `Bearer` 令牌不是唯一的选择。
    
        但它是最适合这个用例的方案。
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Wed Mar 13 19:02:19 UTC 2024
    - 7.4K bytes
    - Viewed (0)
  7. docs/zh/docs/tutorial/security/simple-oauth2.md

    ```Python hl_lines="58-67  69-72  90"
    {!../../../docs_src/security/tutorial003.py!}
    ```
    
    !!! info "说明"
    
        此处返回值为 `Bearer` 的响应头 `WWW-Authenticate` 也是规范的一部分。
    
        任何 401**UNAUTHORIZED**HTTP(错误)状态码都应返回 `WWW-Authenticate` 响应头。
    
        本例中,因为使用的是 Bearer Token,该响应头的值应为 `Bearer`。
    
        实际上,忽略这个附加响应头,也不会有什么问题。
    
        之所以在此提供这个附加响应头,是为了符合规范的要求。
    
        说不定什么时候,就有工具用得上它,而且,开发者或用户也可能用得上。
    
        这就是遵循标准的好处……
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 8.8K bytes
    - Viewed (0)
  8. staging/src/k8s.io/apiserver/pkg/authentication/request/bearertoken/bearertoken_test.go

    			ExpectedErr:                  true,
    			ExpectedAuthorizationHeaders: []string{"Bearer 123"},
    		},
    		"valid bearer token with a space": {
    			AuthorizationHeaders:         []string{"Bearer  token"},
    			ExpectedUserName:             "",
    			ExpectedOK:                   false,
    			ExpectedErr:                  false,
    			ExpectedAuthorizationHeaders: []string{"Bearer  token"},
    			ExpectedRecordedWarning:      invalidTokenWithSpaceWarning,
    		},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Apr 25 13:22:28 UTC 2022
    - 8.8K bytes
    - Viewed (0)
  9. docs/en/docs/tutorial/cors.md

    But that will only allow certain types of communication, excluding everything that involves credentials: Cookies, Authorization headers like those used with Bearer Tokens, etc.
    
    So, for everything to work correctly, it's better to specify explicitly the allowed origins.
    
    ## Use `CORSMiddleware`
    
    You can configure it in your **FastAPI** application using the `CORSMiddleware`.
    
    * Import `CORSMiddleware`.
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sun Nov 13 20:28:37 UTC 2022
    - 5.1K bytes
    - Viewed (0)
  10. api/openapi-spec/v3/logs_openapi.json

    {
      "components": {
        "securitySchemes": {
          "BearerToken": {
            "description": "Bearer Token authentication",
            "in": "header",
            "name": "authorization",
            "type": "apiKey"
          }
        }
      },
      "info": {
        "title": "Kubernetes",
        "version": "unversioned"
      },
      "openapi": "3.0.0",
      "paths": {
        "/logs/": {
          "get": {
            "operationId": "logFileListHandler",
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Mar 30 00:49:56 UTC 2022
    - 1.1K bytes
    - Viewed (0)
Back to top