Microservice to bring 2FA to self hosted PDSes

/account/sign-in not working #3

closed
opened by baileytownsend.dev

The /account/sign-in is no longer working. I'm thinking it is expecting a remember me but there is not one on that request so remember me needs to be optional

Is this when navigating to the PDS account sign in so that you can see connected apps etc on your account?

I'm seeing the same thing. There are logs in the PDS that has an error message if useful.

{
  "name": "pds",
  "err": {
    "type": "BadRequestError",
    "message": "Forbidden sec-fetch-dest header \"empty\" (expected ,document,style,script)",
    "stack": "BadRequestError: Forbidden sec-fetch-dest header \"empty\" (expected ,document,style,script)\n    at validateHeaderValue (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/http/request.ts:25:26)\n    at validateFetchDest (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/http/request.ts:67:3)\n    at assetsMiddleware (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/router/assets/assets-manifest.ts:66:24)\n    at nextMiddleware (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/http/middleware.ts:38:27)\n    at <anonymous> (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/util/function.ts:31:17)\n    at assetsMiddleware (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/router/assets/assets-manifest.ts:60:24)\n    at nextMiddleware (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/http/middleware.ts:38:27)\n    at <anonymous> (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/http/middleware.ts:41:5)\n    at nextMiddleware (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/http/middleware.ts:38:27)\n    at <anonymous> (/app/node_modules/.pnpm/@atproto+oauth-provider@0.10.2/node_modules/@atproto/oauth-provider/src/lib/http/middleware.ts:41:5)",
    "status": 400,
    "statusCode": 400,
    "expose": true
  },
  "msg": "unexpected internal server error"
}

Yep! I think it's this remember needs a #[serde(skip_serializing_if = "Option::is_none", rename = "emailOtp")]

https://tangled.org/@baileytownsend.dev/pds-gatekeeper/blob/main/src/oauth_provider.rs#L16

Oh nice. Iโ€™ll give that a go and test it out then ๐Ÿ™‚

sign up or login to add to the discussion
Labels
good-first-issue
Participants 2
AT URI
at://did:plc:rnpkyqnmsw4ipey6eotbdnnf/sh.tangled.repo.issue/3lykplgsujq22