Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for verify_token (0.11 sec)

  1. docs_src/dependencies/tutorial012_an_py39.py

    from fastapi import Depends, FastAPI, Header, HTTPException
    from typing_extensions import Annotated
    
    
    async def verify_token(x_token: Annotated[str, Header()]):
        if x_token != "fake-super-secret-token":
            raise HTTPException(status_code=400, detail="X-Token header invalid")
    
    
    async def verify_key(x_key: Annotated[str, Header()]):
        if x_key != "fake-super-secret-key":
            raise HTTPException(status_code=400, detail="X-Key header invalid")
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 756 bytes
    - Viewed (0)
  2. docs_src/dependencies/tutorial006.py

    from fastapi import Depends, FastAPI, Header, HTTPException
    
    app = FastAPI()
    
    
    async def verify_token(x_token: str = Header()):
        if x_token != "fake-super-secret-token":
            raise HTTPException(status_code=400, detail="X-Token header invalid")
    
    
    async def verify_key(x_key: str = Header()):
        if x_key != "fake-super-secret-key":
            raise HTTPException(status_code=400, detail="X-Key header invalid")
        return x_key
    
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri May 13 23:38:22 UTC 2022
    - 583 bytes
    - Viewed (0)
  3. docs_src/dependencies/tutorial012.py

    from fastapi import Depends, FastAPI, Header, HTTPException
    
    
    async def verify_token(x_token: str = Header()):
        if x_token != "fake-super-secret-token":
            raise HTTPException(status_code=400, detail="X-Token header invalid")
    
    
    async def verify_key(x_key: str = Header()):
        if x_key != "fake-super-secret-key":
            raise HTTPException(status_code=400, detail="X-Key header invalid")
        return x_key
    
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri May 13 23:38:22 UTC 2022
    - 696 bytes
    - Viewed (0)
  4. docs_src/dependencies/tutorial006_an.py

    from fastapi import Depends, FastAPI, Header, HTTPException
    from typing_extensions import Annotated
    
    app = FastAPI()
    
    
    async def verify_token(x_token: Annotated[str, Header()]):
        if x_token != "fake-super-secret-token":
            raise HTTPException(status_code=400, detail="X-Token header invalid")
    
    
    async def verify_key(x_key: Annotated[str, Header()]):
        if x_key != "fake-super-secret-key":
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 643 bytes
    - Viewed (0)
  5. docs_src/dependencies/tutorial006_an_py39.py

    from typing import Annotated
    
    from fastapi import Depends, FastAPI, Header, HTTPException
    
    app = FastAPI()
    
    
    async def verify_token(x_token: Annotated[str, Header()]):
        if x_token != "fake-super-secret-token":
            raise HTTPException(status_code=400, detail="X-Token header invalid")
    
    
    async def verify_key(x_key: Annotated[str, Header()]):
        if x_key != "fake-super-secret-key":
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 633 bytes
    - Viewed (0)
  6. docs_src/dependencies/tutorial012_an.py

    from fastapi import Depends, FastAPI, Header, HTTPException
    from typing_extensions import Annotated
    
    
    async def verify_token(x_token: Annotated[str, Header()]):
        if x_token != "fake-super-secret-token":
            raise HTTPException(status_code=400, detail="X-Token header invalid")
    
    
    async def verify_key(x_key: Annotated[str, Header()]):
        if x_key != "fake-super-secret-key":
            raise HTTPException(status_code=400, detail="X-Key header invalid")
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 756 bytes
    - Viewed (0)
  7. src/main/java/org/codelibs/fess/app/web/admin/suggest/AdminSuggestAction.java

                        () -> asHtml(path_AdminSuggest_AdminSuggestJsp).useForm(SuggestForm.class));
            }
            saveInfo(messages -> messages.addSuccessDeleteDocFromIndex(GLOBAL));
            verifyToken(() -> asHtml(path_AdminSuggest_AdminSuggestJsp).useForm(SuggestForm.class));
            return redirect(getClass());
        }
    
        @Execute
        @Secured({ ROLE })
        public HtmlResponse deleteDocumentWords() {
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 22 01:53:18 UTC 2024
    - 4.3K bytes
    - Viewed (0)
  8. src/main/java/org/codelibs/fess/app/web/admin/searchlog/AdminSearchlogAction.java

        @Execute
        @Secured({ ROLE })
        public HtmlResponse delete(final EditForm form) {
            verifyCrudMode(form.crudMode, CrudMode.DETAILS);
            validate(form, messages -> {}, this::asDetailsHtml);
            verifyToken(this::asDetailsHtml);
            searchLogService.getSearchLog(form.logType, form.id).alwaysPresent(e -> {
                searchLogService.deleteSearchLog(e);
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 22 01:53:18 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  9. src/main/java/org/codelibs/fess/app/web/admin/failureurl/AdminFailureurlAction.java

        @Execute
        @Secured({ ROLE })
        public HtmlResponse delete(final EditForm form) {
            verifyCrudMode(form.crudMode, CrudMode.DETAILS);
            validate(form, messages -> {}, this::asDetailsHtml);
            verifyToken(this::asDetailsHtml);
            final String id = form.id;
            failureUrlService.getFailureUrl(id).alwaysPresent(entity -> {
                failureUrlService.delete(entity);
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 22 01:53:18 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  10. src/main/java/org/codelibs/fess/app/web/admin/joblog/AdminJoblogAction.java

        @Execute
        @Secured({ ROLE })
        public HtmlResponse delete(final EditForm form) {
            verifyCrudMode(form.crudMode, CrudMode.DETAILS);
            validate(form, messages -> {}, this::asDetailsHtml);
            verifyToken(this::asDetailsHtml);
            final String id = form.id;
            jobLogService.getJobLog(id).alwaysPresent(entity -> {
                jobLogService.delete(entity);
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 22 01:53:18 UTC 2024
    - 8.4K bytes
    - Viewed (0)
Back to top