- Sort Score
- Num 10 results
- Language All
Results 51 - 60 of 74 for get_current_user (0.07 seconds)
-
docs/pt/docs/tutorial/security/get-current-user.md
{* ../../docs_src/security/tutorial002_an_py310.py hl[5,12:6] *} ## Criar uma dependência `get_current_user` { #create-a-get-current-user-dependency } Vamos criar uma dependência chamada `get_current_user`. Lembra que as dependências podem ter subdependências? `get_current_user` terá uma dependência com o mesmo `oauth2_scheme` que criamos antes.Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Feb 13 13:48:53 GMT 2026 - 4.6K bytes - Click Count (0) -
docs/tr/docs/advanced/security/oauth2-scopes.md
`get_current_active_user` dependency'si, alt-dependency olarak `get_current_user`'ı kullandığı için, `get_current_active_user` üzerinde tanımlanan `"me"` scope'u, `get_current_user`'a geçirilen `security_scopes.scopes` içindeki gerekli scope listesine dahil edilir. *Path operation*'ın kendisi de `"items"` scope'unu tanımlar; bu da `get_current_user`'a geçirilen `security_scopes.scopes` listesinde yer alır.
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 07:53:17 GMT 2026 - 14.7K bytes - Click Count (0) -
docs/uk/docs/advanced/security/oauth2-scopes.md
Оскільки залежність `get_current_active_user` має підзалежність `get_current_user`, scope «me», оголошений у `get_current_active_user`, буде включений до списку потрібних scopes у `security_scopes.scopes`, переданого до `get_current_user`. Сама операція шляху також оголошує scope «items», отже він також буде у списку `security_scopes.scopes`, переданому до `get_current_user`. Ось як виглядає ієрархія залежностей і scopes:
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 18:27:41 GMT 2026 - 20.2K bytes - Click Count (0) -
docs/pt/docs/advanced/security/oauth2-scopes.md
Como a dependência `get_current_active_user` possui uma subdependência em `get_current_user`, o escopo `"me"` declarado em `get_current_active_user` será incluído na lista de escopos necessários em `security_scopes.scopes` passado para `get_current_user`. A própria *operação de rota* também declara o escopo, `"items"`, então ele também estará na lista de `security_scopes.scopes` passado para o `get_current_user`.
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 18:20:43 GMT 2026 - 14.9K bytes - Click Count (0) -
docs/ru/docs/advanced/security/oauth2-scopes.md
Так как у зависимости `get_current_active_user` есть подзависимость `get_current_user`, scope `"me"`, объявленный в `get_current_active_user`, будет включён в список требуемых scopes в `security_scopes.scopes`, передаваемый в `get_current_user`. Сама операция пути тоже объявляет scope — `"items"`, поэтому он также будет в списке `security_scopes.scopes`, передаваемом в `get_current_user`. Иерархия зависимостей и scopes выглядит так:
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 17:56:20 GMT 2026 - 20.6K bytes - Click Count (0) -
docs/ja/docs/tutorial/security/oauth2-jwt.md
レスポンスのトークンエンドポイントで使用するPydanticモデルを定義します。 新しいアクセストークンを生成するユーティリティ関数を作成します。 {* ../../docs_src/security/tutorial004_an_py310.py hl[4,7,13:15,29:31,82:90] *} ## 依存関係の更新 { #update-the-dependencies } `get_current_user`を更新して、先ほどと同じトークンを受け取るようにしますが、今回はJWTトークンを使用します。 受け取ったトークンをデコードして検証し、現在のユーザーを返します。 トークンが無効な場合は、すぐにHTTPエラーを返します。 {* ../../docs_src/security/tutorial004_an_py310.py hl[93:110] *}Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 14:07:17 GMT 2026 - 14.6K bytes - Click Count (1) -
docs/ko/docs/advanced/security/oauth2-scopes.md
## 의존성 트리와 스코프 { #dependency-tree-and-scopes } 이 의존성 트리와 스코프를 다시 살펴보겠습니다. `get_current_active_user` 의존성은 `get_current_user`를 하위 의존성으로 가지므로, `get_current_active_user`에서 선언된 스코프 `"me"`는 `get_current_user`에 전달되는 `security_scopes.scopes`의 요구 스코프 목록에 포함됩니다. *경로 처리* 자체도 스코프 `"items"`를 선언하므로, 이것 또한 `get_current_user`에 전달되는 `security_scopes.scopes` 목록에 포함됩니다. 의존성과 스코프의 계층 구조는 다음과 같습니다: * *경로 처리* `read_own_items`는:Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 14:06:26 GMT 2026 - 15.7K bytes - Click Count (0) -
docs/uk/docs/tutorial/security/simple-oauth2.md
Тепер оновимо наші залежності. Ми хочемо отримати `current_user` лише якщо цей користувач активний. Тому створимо додаткову залежність `get_current_active_user`, яка своєю чергою використовує як залежність `get_current_user`. Обидві ці залежності просто повернуть HTTP-помилку, якщо користувача не існує або він неактивний.
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 18:27:41 GMT 2026 - 15K bytes - Click Count (0) -
docs/ru/docs/tutorial/security/simple-oauth2.md
Мы хотим получить `current_user` только если этот пользователь активен. Поэтому мы создаём дополнительную зависимость `get_current_active_user`, которая, в свою очередь, использует в качестве зависимости `get_current_user`. Обе эти зависимости просто вернут HTTP-ошибку, если пользователь не существует или неактивен.
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 17:56:20 GMT 2026 - 16.2K bytes - Click Count (0) -
docs/tr/docs/tutorial/security/oauth2-jwt.md
Yeni bir access token üretmek için bir yardımcı fonksiyon oluşturun. {* ../../docs_src/security/tutorial004_an_py310.py hl[4,7,13:15,29:31,82:90] *} ## Dependency'leri güncelleme { #update-the-dependencies } `get_current_user` fonksiyonunu, öncekiyle aynı token'ı alacak şekilde güncelleyelim; ancak bu sefer JWT token'larını kullanacağız. Gelen token'ı decode edin, doğrulayın ve mevcut kullanıcıyı döndürün.Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 07:53:17 GMT 2026 - 12.1K bytes - Click Count (0)