@maronn-openid-connect/cli 0.7.1 → 0.8.0
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/README.md +83 -7
- package/dist/frameworks/hono/index.d.ts.map +1 -1
- package/dist/frameworks/hono/index.js +18 -9
- package/dist/frameworks/hono/index.js.map +1 -1
- package/dist/frameworks/hono/pages.d.ts +7 -6
- package/dist/frameworks/hono/pages.d.ts.map +1 -1
- package/dist/frameworks/hono/pages.js +62 -44
- package/dist/frameworks/hono/pages.js.map +1 -1
- package/dist/frameworks/hono/templates.d.ts +19 -6
- package/dist/frameworks/hono/templates.d.ts.map +1 -1
- package/dist/frameworks/hono/templates.js +284 -304
- package/dist/frameworks/hono/templates.js.map +1 -1
- package/dist/frameworks/hono/views.d.ts +3 -0
- package/dist/frameworks/hono/views.d.ts.map +1 -0
- package/dist/frameworks/hono/views.js +458 -0
- package/dist/frameworks/hono/views.js.map +1 -0
- package/dist/frameworks/nextjs/authorize.d.ts +3 -0
- package/dist/frameworks/nextjs/authorize.d.ts.map +1 -0
- package/dist/frameworks/nextjs/authorize.js +757 -0
- package/dist/frameworks/nextjs/authorize.js.map +1 -0
- package/dist/frameworks/nextjs/ciba.d.ts +8 -0
- package/dist/frameworks/nextjs/ciba.d.ts.map +1 -0
- package/dist/frameworks/nextjs/ciba.js +591 -0
- package/dist/frameworks/nextjs/ciba.js.map +1 -0
- package/dist/frameworks/nextjs/conformance.d.ts +3 -0
- package/dist/frameworks/nextjs/conformance.d.ts.map +1 -0
- package/dist/frameworks/nextjs/conformance.js +2447 -0
- package/dist/frameworks/nextjs/conformance.js.map +1 -0
- package/dist/frameworks/nextjs/device.d.ts +8 -0
- package/dist/frameworks/nextjs/device.d.ts.map +1 -0
- package/dist/frameworks/nextjs/device.js +662 -0
- package/dist/frameworks/nextjs/device.js.map +1 -0
- package/dist/frameworks/nextjs/endpoints.d.ts +7 -0
- package/dist/frameworks/nextjs/endpoints.d.ts.map +1 -0
- package/dist/frameworks/nextjs/endpoints.js +673 -0
- package/dist/frameworks/nextjs/endpoints.js.map +1 -0
- package/dist/frameworks/nextjs/index.d.ts.map +1 -1
- package/dist/frameworks/nextjs/index.js +135 -2
- package/dist/frameworks/nextjs/index.js.map +1 -1
- package/dist/frameworks/nextjs/interaction.d.ts +13 -0
- package/dist/frameworks/nextjs/interaction.d.ts.map +1 -0
- package/dist/frameworks/nextjs/interaction.js +864 -0
- package/dist/frameworks/nextjs/interaction.js.map +1 -0
- package/dist/frameworks/nextjs/logout.d.ts +5 -0
- package/dist/frameworks/nextjs/logout.d.ts.map +1 -0
- package/dist/frameworks/nextjs/logout.js +271 -0
- package/dist/frameworks/nextjs/logout.js.map +1 -0
- package/dist/frameworks/nextjs/metadata.d.ts +6 -0
- package/dist/frameworks/nextjs/metadata.d.ts.map +1 -0
- package/dist/frameworks/nextjs/metadata.js +339 -0
- package/dist/frameworks/nextjs/metadata.js.map +1 -0
- package/dist/frameworks/nextjs/provider.d.ts +6 -0
- package/dist/frameworks/nextjs/provider.d.ts.map +1 -0
- package/dist/frameworks/nextjs/provider.js +797 -0
- package/dist/frameworks/nextjs/provider.js.map +1 -0
- package/dist/frameworks/nextjs/token.d.ts +7 -0
- package/dist/frameworks/nextjs/token.d.ts.map +1 -0
- package/dist/frameworks/nextjs/token.js +1337 -0
- package/dist/frameworks/nextjs/token.js.map +1 -0
- package/dist/frameworks/web-standard/templates.d.ts +1 -13
- package/dist/frameworks/web-standard/templates.d.ts.map +1 -1
- package/dist/frameworks/web-standard/templates.js +12 -1296
- package/dist/frameworks/web-standard/templates.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +38 -8
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,9 +1,142 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { DEFAULT_FEATURES } from '../../features.js';
|
|
2
|
+
import { configTemplate, customScopesTemplate, jarmConfigTemplate, resolversTemplate, storeTemplate, } from '../hono/templates.js';
|
|
3
|
+
import { nextJsHtmlTemplate, nextJsHttpTemplate, nextJsProviderTemplate, nextJsStorageBackendTemplate, } from './provider.js';
|
|
4
|
+
import { nextJsDiscoveryRouteTemplate, nextJsJwksRouteTemplate } from './metadata.js';
|
|
5
|
+
import { nextJsAuthorizeRouteTemplate } from './authorize.js';
|
|
6
|
+
import { nextJsCibaGrantTemplate, nextJsDeviceCodeGrantTemplate, nextJsIdJagGrantTemplate, nextJsTokenExchangeGrantTemplate, nextJsTokenRouteTemplate, } from './token.js';
|
|
7
|
+
import { nextJsIntrospectionRouteTemplate, nextJsParConfigTemplate, nextJsParRouteTemplate, nextJsRevocationRouteTemplate, nextJsUserinfoRouteTemplate, } from './endpoints.js';
|
|
8
|
+
import { nextJsDeviceApproveRouteTemplate, nextJsDeviceAuthorizationConfigTemplate, nextJsDeviceAuthorizationRouteTemplate, nextJsDeviceLoginRouteTemplate, nextJsDeviceRouteTemplate, nextJsDeviceScreensTemplate, } from './device.js';
|
|
9
|
+
import { nextJsBackchannelAuthenticationRouteTemplate, nextJsCibaApproveRouteTemplate, nextJsCibaConfigTemplate, nextJsCibaLoginRouteTemplate, nextJsCibaRouteTemplate, nextJsCibaScreensTemplate, } from './ciba.js';
|
|
10
|
+
import { nextJsLogoutApproveRouteTemplate, nextJsLogoutConfigTemplate, nextJsLogoutRouteTemplate, nextJsLogoutScreensTemplate, } from './logout.js';
|
|
11
|
+
import { nextJsConsentActionTemplate, nextJsConsentPageTemplate, nextJsErrorBoundaryTemplate, nextJsErrorPageTemplate, nextJsErrorViewTemplate, nextJsGoogleLoginRouteTemplate, nextJsLoginActionTemplate, nextJsLoginPageTemplate, nextJsLoginSessionTemplate, nextJsNotFoundTemplate, nextJsTransactionTemplate, } from './interaction.js';
|
|
12
|
+
import { nextJsConformanceTestTemplate } from './conformance.js';
|
|
2
13
|
export class NextJsGenerator {
|
|
3
14
|
name = 'nextjs';
|
|
4
15
|
displayName = 'Next.js';
|
|
5
16
|
generate(options) {
|
|
6
|
-
|
|
17
|
+
const pkg = options.corePackageName;
|
|
18
|
+
const features = options.features ?? DEFAULT_FEATURES;
|
|
19
|
+
const scopes = options.scopes ?? [];
|
|
20
|
+
return nextJsGeneratedFiles(pkg, features, scopes);
|
|
7
21
|
}
|
|
8
22
|
}
|
|
23
|
+
const NEXTJS_SCOPE_POLICY_FILE_REFS = {
|
|
24
|
+
userinfo: 'userinfo/route.ts',
|
|
25
|
+
consent: 'consent/page.tsx + consent/actions.ts',
|
|
26
|
+
authorize: 'authorize/route.ts',
|
|
27
|
+
approvals: 'device/approve/route.ts / ciba/approve/route.ts',
|
|
28
|
+
};
|
|
29
|
+
function withBundlerImports(content) {
|
|
30
|
+
return content.replaceAll(/(from\s+['"](?:\.{1,2}\/[^'"]+))\.js(['"])/g, '$1$2');
|
|
31
|
+
}
|
|
32
|
+
function nextJsGeneratedFiles(pkg, features, scopes) {
|
|
33
|
+
const servesHtmlFromRouteHandlers = features.deviceAuthorizationGrant || features.ciba || features.rpInitiatedLogout;
|
|
34
|
+
return [
|
|
35
|
+
{ path: '_oidc-provider/provider.ts', content: nextJsProviderTemplate(pkg, features) },
|
|
36
|
+
{
|
|
37
|
+
path: '_oidc-provider/config.ts',
|
|
38
|
+
content: withBundlerImports(configTemplate(pkg, features, { authorizationErrorRedirectPath: false })),
|
|
39
|
+
},
|
|
40
|
+
{ path: '_oidc-provider/store.ts', content: withBundlerImports(storeTemplate(pkg, features)) },
|
|
41
|
+
{
|
|
42
|
+
path: '_oidc-provider/resolvers.ts',
|
|
43
|
+
content: withBundlerImports(resolversTemplate(pkg, features, 'The Next.js endpoints use the client resolver built in provider.ts instead.')),
|
|
44
|
+
},
|
|
45
|
+
{ path: '_oidc-provider/storage-backend.ts', content: nextJsStorageBackendTemplate() },
|
|
46
|
+
{ path: '_oidc-provider/http.ts', content: nextJsHttpTemplate() },
|
|
47
|
+
{ path: '_oidc-provider/transaction.ts', content: nextJsTransactionTemplate(pkg, features) },
|
|
48
|
+
{ path: '_oidc-provider/error-view.tsx', content: nextJsErrorViewTemplate() },
|
|
49
|
+
...(servesHtmlFromRouteHandlers
|
|
50
|
+
? [{ path: '_oidc-provider/html.ts', content: nextJsHtmlTemplate() }]
|
|
51
|
+
: []),
|
|
52
|
+
...(scopes.length > 0
|
|
53
|
+
? [{
|
|
54
|
+
path: '_oidc-provider/scopes.ts',
|
|
55
|
+
content: withBundlerImports(customScopesTemplate(scopes, features, NEXTJS_SCOPE_POLICY_FILE_REFS)),
|
|
56
|
+
}]
|
|
57
|
+
: []),
|
|
58
|
+
...(features.jarm
|
|
59
|
+
? [{ path: '_oidc-provider/jarm.ts', content: withBundlerImports(jarmConfigTemplate()) }]
|
|
60
|
+
: []),
|
|
61
|
+
{
|
|
62
|
+
path: '_oidc-provider/conformance.test.ts',
|
|
63
|
+
content: nextJsConformanceTestTemplate(features, scopes),
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
path: '.well-known/openid-configuration/route.ts',
|
|
67
|
+
content: nextJsDiscoveryRouteTemplate(pkg, features, scopes),
|
|
68
|
+
},
|
|
69
|
+
{ path: '.well-known/jwks.json/route.ts', content: nextJsJwksRouteTemplate(pkg) },
|
|
70
|
+
{ path: 'authorize/route.ts', content: nextJsAuthorizeRouteTemplate(pkg, features, scopes) },
|
|
71
|
+
{ path: 'login/page.tsx', content: nextJsLoginPageTemplate(features) },
|
|
72
|
+
{ path: 'login/actions.ts', content: nextJsLoginActionTemplate(pkg) },
|
|
73
|
+
{ path: 'login/session.ts', content: nextJsLoginSessionTemplate(pkg, features) },
|
|
74
|
+
{ path: 'login/not-found.tsx', content: nextJsNotFoundTemplate('login') },
|
|
75
|
+
{ path: 'login/error.tsx', content: nextJsErrorBoundaryTemplate('login') },
|
|
76
|
+
...(features.googleLogin
|
|
77
|
+
? [{ path: 'login/google/route.ts', content: nextJsGoogleLoginRouteTemplate(pkg) }]
|
|
78
|
+
: []),
|
|
79
|
+
{ path: 'consent/page.tsx', content: nextJsConsentPageTemplate(features, scopes) },
|
|
80
|
+
{ path: 'consent/actions.ts', content: nextJsConsentActionTemplate(pkg, features, scopes) },
|
|
81
|
+
{ path: 'consent/not-found.tsx', content: nextJsNotFoundTemplate('consent') },
|
|
82
|
+
{ path: 'consent/error.tsx', content: nextJsErrorBoundaryTemplate('consent') },
|
|
83
|
+
{ path: 'oidc-error/page.tsx', content: nextJsErrorPageTemplate() },
|
|
84
|
+
{ path: 'token/route.ts', content: nextJsTokenRouteTemplate(pkg, features) },
|
|
85
|
+
{ path: 'userinfo/route.ts', content: nextJsUserinfoRouteTemplate(pkg) },
|
|
86
|
+
...(features.introspection
|
|
87
|
+
? [{ path: 'introspect/route.ts', content: nextJsIntrospectionRouteTemplate(pkg, features) }]
|
|
88
|
+
: []),
|
|
89
|
+
...(features.revocation
|
|
90
|
+
? [{ path: 'revoke/route.ts', content: nextJsRevocationRouteTemplate(pkg) }]
|
|
91
|
+
: []),
|
|
92
|
+
...(features.par
|
|
93
|
+
? [
|
|
94
|
+
{ path: 'par/route.ts', content: nextJsParRouteTemplate(pkg) },
|
|
95
|
+
{ path: 'par/config.ts', content: nextJsParConfigTemplate() },
|
|
96
|
+
]
|
|
97
|
+
: []),
|
|
98
|
+
...(features.tokenExchange
|
|
99
|
+
? [{ path: 'token/token-exchange.ts', content: nextJsTokenExchangeGrantTemplate(pkg) }]
|
|
100
|
+
: []),
|
|
101
|
+
...(features.idJag
|
|
102
|
+
? [{ path: 'token/id-jag.ts', content: nextJsIdJagGrantTemplate(pkg, features) }]
|
|
103
|
+
: []),
|
|
104
|
+
...(features.deviceAuthorizationGrant
|
|
105
|
+
? [
|
|
106
|
+
{
|
|
107
|
+
path: 'device_authorization/route.ts',
|
|
108
|
+
content: nextJsDeviceAuthorizationRouteTemplate(pkg, features, scopes),
|
|
109
|
+
},
|
|
110
|
+
{ path: 'device_authorization/config.ts', content: nextJsDeviceAuthorizationConfigTemplate() },
|
|
111
|
+
{ path: 'device/route.ts', content: nextJsDeviceRouteTemplate(scopes) },
|
|
112
|
+
{ path: 'device/login/route.ts', content: nextJsDeviceLoginRouteTemplate(pkg, scopes) },
|
|
113
|
+
{ path: 'device/approve/route.ts', content: nextJsDeviceApproveRouteTemplate(scopes) },
|
|
114
|
+
{ path: 'device/screens.ts', content: nextJsDeviceScreensTemplate() },
|
|
115
|
+
{ path: 'token/device-code.ts', content: nextJsDeviceCodeGrantTemplate(pkg, features) },
|
|
116
|
+
]
|
|
117
|
+
: []),
|
|
118
|
+
...(features.ciba
|
|
119
|
+
? [
|
|
120
|
+
{
|
|
121
|
+
path: 'backchannel_authentication/route.ts',
|
|
122
|
+
content: nextJsBackchannelAuthenticationRouteTemplate(pkg, features, scopes),
|
|
123
|
+
},
|
|
124
|
+
{ path: 'backchannel_authentication/config.ts', content: nextJsCibaConfigTemplate() },
|
|
125
|
+
{ path: 'ciba/route.ts', content: nextJsCibaRouteTemplate() },
|
|
126
|
+
{ path: 'ciba/login/route.ts', content: nextJsCibaLoginRouteTemplate(pkg) },
|
|
127
|
+
{ path: 'ciba/approve/route.ts', content: nextJsCibaApproveRouteTemplate(pkg, scopes) },
|
|
128
|
+
{ path: 'ciba/screens.ts', content: nextJsCibaScreensTemplate(scopes) },
|
|
129
|
+
{ path: 'token/ciba.ts', content: nextJsCibaGrantTemplate(pkg, features) },
|
|
130
|
+
]
|
|
131
|
+
: []),
|
|
132
|
+
...(features.rpInitiatedLogout
|
|
133
|
+
? [
|
|
134
|
+
{ path: 'logout/route.ts', content: nextJsLogoutRouteTemplate(pkg) },
|
|
135
|
+
{ path: 'logout/approve/route.ts', content: nextJsLogoutApproveRouteTemplate() },
|
|
136
|
+
{ path: 'logout/config.ts', content: nextJsLogoutConfigTemplate() },
|
|
137
|
+
{ path: 'logout/screens.ts', content: nextJsLogoutScreensTemplate() },
|
|
138
|
+
]
|
|
139
|
+
: []),
|
|
140
|
+
];
|
|
141
|
+
}
|
|
9
142
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/frameworks/nextjs/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/frameworks/nextjs/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAErD,OAAO,EACL,cAAc,EACd,oBAAoB,EACpB,kBAAkB,EAClB,iBAAiB,EACjB,aAAa,GACd,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,kBAAkB,EAClB,kBAAkB,EAClB,sBAAsB,EACtB,4BAA4B,GAC7B,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,4BAA4B,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAC;AACtF,OAAO,EAAE,4BAA4B,EAAE,MAAM,gBAAgB,CAAC;AAC9D,OAAO,EACL,uBAAuB,EACvB,6BAA6B,EAC7B,wBAAwB,EACxB,gCAAgC,EAChC,wBAAwB,GACzB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,gCAAgC,EAChC,uBAAuB,EACvB,sBAAsB,EACtB,6BAA6B,EAC7B,2BAA2B,GAC5B,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,gCAAgC,EAChC,uCAAuC,EACvC,sCAAsC,EACtC,8BAA8B,EAC9B,yBAAyB,EACzB,2BAA2B,GAC5B,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,4CAA4C,EAC5C,8BAA8B,EAC9B,wBAAwB,EACxB,4BAA4B,EAC5B,uBAAuB,EACvB,yBAAyB,GAC1B,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,gCAAgC,EAChC,0BAA0B,EAC1B,yBAAyB,EACzB,2BAA2B,GAC5B,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,2BAA2B,EAC3B,yBAAyB,EACzB,2BAA2B,EAC3B,uBAAuB,EACvB,uBAAu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AAE,IAAI,EAAE,iBAAiB,EAAE,OAAO,EAAE,yBAAyB,CAAC,MAAM,CAAC,EAAE;gBACvE,EAAE,IAAI,EAAE,eAAe,EAAE,OAAO,EAAE,uBAAuB,CAAC,GAAG,EAAE,QAAQ,CAAC,EAAE;aAC3E;YACD,CAAC,CAAC,EAAE,CAAC;QAEP,GAAG,CAAC,QAAQ,CAAC,iBAAiB;YAC5B,CAAC,CAAC;gBACA,EAAE,IAAI,EAAE,iBAAiB,EAAE,OAAO,EAAE,yBAAyB,CAAC,GAAG,CAAC,EAAE;gBACpE,EAAE,IAAI,EAAE,yBAAyB,EAAE,OAAO,EAAE,gCAAgC,EAAE,EAAE;gBAChF,EAAE,IAAI,EAAE,kBAAkB,EAAE,OAAO,EAAE,0BAA0B,EAAE,EAAE;gBACnE,EAAE,IAAI,EAAE,mBAAmB,EAAE,OAAO,EAAE,2BAA2B,EAAE,EAAE;aACtE;YACD,CAAC,CAAC,EAAE,CAAC;KACR,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { OidcFeatureConfig } from '../../features.js';
|
|
2
|
+
export declare function nextJsLoginSessionTemplate(corePkg: string, features?: OidcFeatureConfig): string;
|
|
3
|
+
export declare function nextJsTransactionTemplate(corePkg: string, features?: OidcFeatureConfig): string;
|
|
4
|
+
export declare function nextJsErrorViewTemplate(): string;
|
|
5
|
+
export declare function nextJsNotFoundTemplate(page: 'login' | 'consent'): string;
|
|
6
|
+
export declare function nextJsErrorBoundaryTemplate(page: 'login' | 'consent'): string;
|
|
7
|
+
export declare function nextJsLoginPageTemplate(features?: OidcFeatureConfig): string;
|
|
8
|
+
export declare function nextJsLoginActionTemplate(corePkg: string): string;
|
|
9
|
+
export declare function nextJsGoogleLoginRouteTemplate(corePkg: string): string;
|
|
10
|
+
export declare function nextJsConsentPageTemplate(features?: OidcFeatureConfig, scopes?: string[]): string;
|
|
11
|
+
export declare function nextJsConsentActionTemplate(corePkg: string, features?: OidcFeatureConfig, scopes?: string[]): string;
|
|
12
|
+
export declare function nextJsErrorPageTemplate(): string;
|
|
13
|
+
//# sourceMappingURL=interaction.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interaction.d.ts","sourceRoot":"","sources":["../../../src/frameworks/nextjs/interaction.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAI3D,wBAAgB,0BAA0B,CACxC,OAAO,EAAE,MAAM,EACf,QAAQ,GAAE,iBAAoC,GAC7C,MAAM,CA4DR;AAGD,wBAAgB,yBAAyB,CACvC,OAAO,EAAE,MAAM,EACf,QAAQ,GAAE,iBAAoC,GAC7C,MAAM,CAyER;AAGD,wBAAgB,uBAAuB,IAAI,MAAM,CA4BhD;AAQD,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,OAAO,GAAG,SAAS,GAAG,MAAM,CAoBxE;AAGD,wBAAgB,2BAA2B,CAAC,IAAI,EAAE,OAAO,GAAG,SAAS,GAAG,MAAM,CAgC7E;AAGD,wBAAgB,uBAAuB,CAAC,QAAQ,GAAE,iBAAoC,GAAG,MAAM,CAkI9F;AAGD,wBAAgB,yBAAyB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CA8DjE;AAGD,wBAAgB,8BAA8B,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CA8FtE;AAGD,wBAAgB,yBAAyB,CACvC,QAAQ,GAAE,iBAAoC,EAC9C,MAAM,GAAE,MAAM,EAAO,GACpB,MAAM,CAmFR;AAGD,wBAAgB,2BAA2B,CACzC,OAAO,EAAE,MAAM,EACf,QAAQ,GAAE,iBAAoC,EAC9C,MAAM,GAAE,MAAM,EAAO,GACpB,MAAM,CAyOR;AAGD,wBAAgB,uBAAuB,IAAI,MAAM,CAkChD"}
|