Harden cross-auth upload recovery claims
Route VOE API and login uploads through one batch-scoped account claim registry so direct identities and uncertain outcomes are shared across authentication paths. Fail closed for ambiguous Doodstream web uploads after POST, use canonical account identities across web and API paths, and singleflight derived API-key resolution outside upload semaphore admission. Preserve distinct symbol-only recovery titles with a stable code-point fallback while matching Unicode-equivalent presentation forms. Add deterministic regression coverage for duplicate identities, uncertain successors, concurrent key resolution, and mixed auth paths.
This commit is contained in:
+6
-1
@@ -575,12 +575,17 @@ async function _fetchByseFileList(apiKey, signal, phase = 'recovery-poll') {
|
||||
}
|
||||
|
||||
function _normalizeFileTitle(s) {
|
||||
return String(s || '')
|
||||
const normalized = String(s || '')
|
||||
.normalize('NFKD')
|
||||
.toLowerCase()
|
||||
.replace(/\.[\p{Letter}\p{Number}]+$/u, '')
|
||||
.replace(/\p{Variation_Selector}+/gu, '');
|
||||
const alphanumeric = normalized
|
||||
.replace(/\p{Mark}+/gu, '')
|
||||
.replace(/[^\p{Letter}\p{Number}]+/gu, '');
|
||||
if (alphanumeric) return alphanumeric;
|
||||
const codePoints = Array.from(normalized, value => value.codePointAt(0).toString(16)).join('-');
|
||||
return `symbols:${codePoints}`;
|
||||
}
|
||||
|
||||
function _normalizeRecoveryHoster(value) {
|
||||
|
||||
Reference in New Issue
Block a user