Skip to content

Commit dca5001

Browse files
authored
update links to ietf docs (#4273)
1 parent 3cd613f commit dca5001

File tree

9 files changed

+16
-16
lines changed

9 files changed

+16
-16
lines changed

packages/oauth/oauth-client/src/oauth-authorization-server-metadata-resolver.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ export class OAuthAuthorizationServerMetadataResolver extends CachedGetter<
108108
}
109109

110110
// ATPROTO requires client_id_metadata_document
111-
// http://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
111+
// https://datatracker.ietf.org/doc/draft-ietf-oauth-client-id-metadata-document/
112112
if (metadata.client_id_metadata_document_supported !== true) {
113113
throw new TypeError(
114114
`Authorization server "${issuer}" does not support client_id_metadata_document`,

packages/oauth/oauth-client/src/oauth-client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ export class OAuthClient extends CustomEventTarget<OAuthClientEventMap> {
131131
throw new TypeError(`Failed to fetch client metadata: ${response.status}`)
132132
}
133133

134-
// https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html#section-4.1
134+
// https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html#section-4.1
135135
const mime = response.headers.get('content-type')?.split(';')[0].trim()
136136
if (mime !== 'application/json') {
137137
response.body?.cancel?.()

packages/oauth/oauth-client/src/oauth-protected-resource-metadata-resolver.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export type OAuthProtectedResourceMetadataResolverConfig = {
2727
}
2828

2929
/**
30-
* @see {@link https://datatracker.ietf.org/doc/html/draft-ietf-oauth-resource-metadata-05}
30+
* @see {@link https://www.rfc-editor.org/rfc/rfc9728.html}
3131
*/
3232
export class OAuthProtectedResourceMetadataResolver extends CachedGetter<
3333
string,
@@ -82,7 +82,7 @@ export class OAuthProtectedResourceMetadataResolver extends CachedGetter<
8282

8383
const response = await this.fetch(request)
8484

85-
// https://datatracker.ietf.org/doc/html/draft-ietf-oauth-resource-metadata-05#section-3.2
85+
// https://www.rfc-editor.org/rfc/rfc9728.html#section-3.2
8686
if (response.status !== 200) {
8787
await cancelBody(response, 'log')
8888
throw await FetchResponseError.from(
@@ -107,7 +107,7 @@ export class OAuthProtectedResourceMetadataResolver extends CachedGetter<
107107
await response.json(),
108108
)
109109

110-
// https://datatracker.ietf.org/doc/html/draft-ietf-oauth-resource-metadata-05#section-3.3
110+
// https://www.rfc-editor.org/rfc/rfc9728.html#section-3.3
111111
if (metadata.resource !== origin) {
112112
throw new TypeError(`Invalid issuer ${metadata.resource}`)
113113
}

packages/oauth/oauth-client/src/oauth-resolver.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ export class OAuthResolver {
158158
options,
159159
)
160160

161-
// https://datatracker.ietf.org/doc/html/draft-ietf-oauth-resource-metadata-05#section-4
161+
// https://www.rfc-editor.org/rfc/rfc9728.html#section-4
162162
if (asMetadata.protected_resources) {
163163
if (!asMetadata.protected_resources.includes(rsMetadata.resource)) {
164164
throw new OAuthResolverError(

packages/oauth/oauth-provider/src/client/client-manager.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ import { Client } from './client.js'
3636

3737
const fetchMetadataHandler = pipe(
3838
fetchOkProcessor(),
39-
// https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html#section-4.1
39+
// https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html#section-4.1
4040
fetchJsonProcessor('application/json', true),
4141
fetchJsonZodProcessor(oauthClientMetadataSchema),
4242
)
@@ -724,7 +724,7 @@ export class ClientManager {
724724
metadata: OAuthClientMetadata,
725725
): OAuthClientMetadata {
726726
if (!metadata.client_id) {
727-
// https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
727+
// https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html
728728
throw new InvalidClientMetadataError(
729729
`client_id is required for discoverable clients`,
730730
)
@@ -733,7 +733,7 @@ export class ClientManager {
733733
const clientIdUrl = parseDiscoverableClientId(clientId)
734734

735735
if (metadata.client_uri) {
736-
// https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
736+
// https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html
737737
//
738738
// The client_uri must be a parent of the client_id URL. This might be
739739
// relaxed in the future.
@@ -773,7 +773,7 @@ export class ClientManager {
773773
// > where two apps claim the same private-use URI scheme (where one
774774
// > app is acting maliciously).
775775

776-
// https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
776+
// https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html
777777
//
778778
// Fully qualified domain name (FQDN) of the client_id, in reverse
779779
// order. This could be relaxed to allow same apex domain names, or

packages/oauth/oauth-provider/src/metadata/build-metadata.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,10 +122,10 @@ export function buildMetadata(
122122
authorization_details_types_supported:
123123
customMetadata?.authorization_details_types_supported,
124124

125-
// https://datatracker.ietf.org/doc/html/draft-ietf-oauth-resource-metadata-05#section-4
125+
// https://www.rfc-editor.org/rfc/rfc9728.html#section-4
126126
protected_resources: customMetadata?.protected_resources,
127127

128-
// https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
128+
// https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html
129129
client_id_metadata_document_supported: true,
130130
})
131131
}

packages/oauth/oauth-types/src/oauth-authorization-server-metadata.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,10 @@ export const oauthAuthorizationServerMetadataSchema = z.object({
6767
// https://datatracker.ietf.org/doc/html/rfc9449#section-5.1
6868
dpop_signing_alg_values_supported: z.array(z.string()).optional(),
6969

70-
// https://datatracker.ietf.org/doc/html/draft-ietf-oauth-resource-metadata-05#section-4
70+
// https://www.rfc-editor.org/rfc/rfc9728.html#section-4
7171
protected_resources: z.array(webUriSchema).optional(),
7272

73-
// https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
73+
// https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html
7474
client_id_metadata_document_supported: z.boolean().optional(),
7575
})
7676

packages/oauth/oauth-types/src/oauth-client-id-discoverable.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { httpsUriSchema } from './uri.js'
44
import { extractUrlPath, isHostnameIP } from './util.js'
55

66
/**
7-
* @see {@link https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html}
7+
* @see {@link https://www.ietf.org/archive/id/draft-ietf-oauth-client-id-metadata-document-00.html}
88
*/
99
export const oauthClientIdDiscoverableSchema = z
1010
.intersection(oauthClientIdSchema, httpsUriSchema)

packages/oauth/oauth-types/src/oauth-protected-resource-metadata.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { oauthIssuerIdentifierSchema } from './oauth-issuer-identifier.js'
33
import { webUriSchema } from './uri.js'
44

55
/**
6-
* @see {@link https://datatracker.ietf.org/doc/html/draft-ietf-oauth-resource-metadata-05#name-protected-resource-metadata-r}
6+
* @see {@link https://www.rfc-editor.org/rfc/rfc9728.html#section-3.2}
77
*/
88
export const oauthProtectedResourceMetadataSchema = z.object({
99
/**

0 commit comments

Comments
 (0)