You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 990a5fc
Browse filesBrowse the repository at this point in the historyBrowse files
Treat username "UnknownUser" as explicit unauthenticated access (#366)
* Treat username "UnknownUser" as explicit unauthenticated access
- BasicAuthorization: UnknownUser is resolved with an empty accessToken, empty header and no credentials;
empty passwords are ignored, as for OAuth2 tokens
- createSession: a blank or typed UnknownUser needs no password; a requested user that differs from the
configured one does not inherit the configured password
- resolveCredentials passes the session username through instead of mapping UnknownUser to ""
- Settings schema: password requires username and is rejected alongside UnknownUser (any casing)
- Add-server wizard writes username UnknownUser for the Unauthenticated choice
- README documents UnknownUser as the only way to request unauthenticated access
* Probe username-less servers once per session and record UnknownUser through a serialized settings writer
- serverSetting.ts: updateConfig(scope, update) hands the 'intersystems.servers' value at each writable
target to a pure function and writes back what it returns, queued behind earlier writes; undefined
entries are ignored rather than deleting a target
- getServerSpec: for a stored definition with neither username nor password, GET the Atelier root once per
session per folder in the background; on a genuine server-info response set username UnknownUser at the
defining target and toast. Legacy embedded servers are not probed
- addServer and the registry import write through updateConfig
- IServerSetting is based on IJSONServerSpec so it no longer carries name
* update
* no timeout needed
* clean up
* Move BasicAuthorization into the types package and adopt the IJSONServerSpec/IServerSpec reshaping
types 3.15.0-beta.2, generated from a single types/index.ts:
- BasicAuthorization is exported for all extensions; base64 via TextEncoder/btoa so it also runs
in the web bundle, and httpAuthorizationHeader is undefined while unresolved
- IJSONServerSpec is one intersystems.servers entry (gains oauth2, loses auth); IServerSpec adds
name and auth and deprecates username/password; IServerSpecWithAuth removed
- Authorization and ResolvedAuthorization unchanged
- index.js and index.d.ts are build outputs, kept committed and regenerated by prepublishOnly
Extension: pin the published beta exactly; drop the local class and the internal IServerSetting/
OAuth2Config in favour of the package types; exclude types/ from the root tsconfig.
* Stop committing the generated types/index.js and index.d.ts
They are build outputs of types/index.ts, produced by npm run build and by prepublishOnly.
Copy file name to clipboardExpand all lines: README.md
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,6 +61,10 @@ If instead you press 'Enter' the password will be available only until you resta
61
61
62
62
Either way, you are now signed in on the specified account.
63
63
64
+
### Unauthenticated Access
65
+
66
+
To connect without credentials, set `"username": "UnknownUser"`. Omitting `username` does not request unauthenticated access; expect to be prompted for one.
67
+
64
68
### Trusting Other Extensions
65
69
66
70
When another extension first asks to use an InterSystems Server Credentials account you must either allow this or deny it. For example, when the InterSystems ObjectScript extension uses the new authentication provider you get this dialog after you click the edit pencil button alongside a namespace in the [Server Manager tree](#the-server-tree):
.catch((error)=>logger?.warn(`Probed ${url} for unauthenticated access (to record username 'UnknownUser') but failed to end the server session it opened: ${error}`));
35
+
}
36
+
// Require a genuine Atelier server-info document, so a proxy or login page answering 200 is not mistaken for access
`Server '${name}' allowed unauthenticated access, so its 'username' setting has been set to 'UnknownUser'. A future release will always prompt for a username when none is set.`,
62
+
"Dismiss",
63
+
);
64
+
}
65
+
}catch(error){
66
+
logger?.warn(`Failed to set username of '${name}' to UnknownUser: ${error}`);
67
+
}
68
+
}
5
69
6
70
/**
7
71
* Get a server specification.
@@ -13,9 +77,10 @@ import { IServerSetting } from "../serverSetting";
0 commit comments