mirror of
https://github.com/fosrl/pangolin.git
synced 2025-07-15 08:25:01 +02:00
add pass access token in headers
This commit is contained in:
parent
74d6b3d902
commit
6cc4bc2645
14 changed files with 333 additions and 161 deletions
|
@ -11,8 +11,7 @@ import { fromError } from "zod-validation-error";
|
|||
import { createResourceSession } from "@server/auth/sessions/resource";
|
||||
import logger from "@server/logger";
|
||||
import {
|
||||
verifyResourceAccessToken,
|
||||
verifyResourceAccessTokenSHA256
|
||||
verifyResourceAccessToken
|
||||
} from "@server/auth/verifyResourceAccessToken";
|
||||
import config from "@server/lib/config";
|
||||
import stoi from "@server/lib/stoi";
|
||||
|
@ -98,7 +97,6 @@ export async function authWithAccessToken(
|
|||
}
|
||||
|
||||
const res = await verifyResourceAccessToken({
|
||||
resource: foundResource,
|
||||
accessTokenId,
|
||||
accessToken
|
||||
});
|
||||
|
@ -108,7 +106,7 @@ export async function authWithAccessToken(
|
|||
error = res.error;
|
||||
resource = foundResource;
|
||||
} else {
|
||||
const res = await verifyResourceAccessTokenSHA256({
|
||||
const res = await verifyResourceAccessToken({
|
||||
accessToken
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue