mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-18 07:23:20 +08:00
fix(uds-auth): isolate trusted Host calls from browser identity
This commit is contained in:
parent
3ba4461566
commit
fa4d5d6d97
7 changed files with 83 additions and 3 deletions
|
|
@ -21,6 +21,7 @@ import {
|
|||
LOCAL_ADMIN_BOX_ENV,
|
||||
} from './local-admin.js'
|
||||
import { SessionBridgeStore } from './session-bridge.js'
|
||||
import { runAsHost } from './context.js'
|
||||
|
||||
const __dirname = dirname(fileURLToPath(import.meta.url))
|
||||
const require = createRequire(import.meta.url)
|
||||
|
|
@ -1267,6 +1268,7 @@ async function initServices(ctx, config) {
|
|||
}
|
||||
|
||||
const udsAuth = {
|
||||
runAsHost,
|
||||
async resolveRequestIdentity(req) {
|
||||
const identity = await resolveIdentity(req)
|
||||
if (!identity?.empNo) return null
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue