@atcute/oauth-browser-client 1.0.24 → 1.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/agents/exchange.js
CHANGED
|
@@ -11,7 +11,7 @@ import { storeSession } from './sessions.js';
|
|
|
11
11
|
* @returns URL to redirect the user for authorization
|
|
12
12
|
*/
|
|
13
13
|
export const createAuthorizationUrl = async ({ metadata, identity, scope, }) => {
|
|
14
|
-
const state = nanoid(
|
|
14
|
+
const state = nanoid(24);
|
|
15
15
|
const pkce = await generatePKCE();
|
|
16
16
|
const dpopKey = await createES256Key();
|
|
17
17
|
const params = {
|
package/dist/utils/runtime.js
CHANGED
|
@@ -8,7 +8,7 @@ export const stringToSha256 = async (input) => {
|
|
|
8
8
|
return toBase64Url(digest);
|
|
9
9
|
};
|
|
10
10
|
export const generatePKCE = async () => {
|
|
11
|
-
const verifier = nanoid(
|
|
11
|
+
const verifier = nanoid(64);
|
|
12
12
|
return {
|
|
13
13
|
verifier: verifier,
|
|
14
14
|
challenge: await stringToSha256(verifier),
|
package/lib/agents/exchange.ts
CHANGED
package/lib/utils/runtime.ts
CHANGED
|
@@ -13,7 +13,7 @@ export const stringToSha256 = async (input: string): Promise<string> => {
|
|
|
13
13
|
};
|
|
14
14
|
|
|
15
15
|
export const generatePKCE = async (): Promise<{ verifier: string; challenge: string; method: string }> => {
|
|
16
|
-
const verifier = nanoid(
|
|
16
|
+
const verifier = nanoid(64);
|
|
17
17
|
|
|
18
18
|
return {
|
|
19
19
|
verifier: verifier,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"type": "module",
|
|
3
3
|
"name": "@atcute/oauth-browser-client",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.25",
|
|
5
5
|
"description": "minimal OAuth browser client implementation for AT Protocol",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"@atcute/identity": "^1.0.2",
|
|
24
24
|
"@atcute/lexicons": "^1.0.4",
|
|
25
25
|
"@atcute/client": "^4.0.3",
|
|
26
|
-
"@atcute/
|
|
27
|
-
"@atcute/
|
|
26
|
+
"@atcute/multibase": "^1.1.4",
|
|
27
|
+
"@atcute/uint8array": "^1.0.3"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
30
|
"@atcute/atproto": "^3.0.3"
|