nextcloud/server · error · Error
Could not register device: Network error
Error message
Could not register device: Network error
What it means
Error "Could not register device: Network error" thrown in nextcloud/server.
Source
Thrown at apps/settings/src/service/WebAuthnRegistrationSerice.ts:31
/**
* Start registering a new device
*
* @return The device attributes
*/
export async function startRegistration() {
const url = generateUrl('/settings/api/personal/webauthn/registration')
try {
logger.debug('Fetching webauthn registration data')
const { data } = await axios.get<PublicKeyCredentialCreationOptionsJSON>(url)
logger.debug('Start webauthn registration')
const attrs = await registerWebAuthn({ optionsJSON: data })
return attrs
} catch (e) {
logger.error(e as Error)
if (isAxiosError(e)) {
throw new Error(t('settings', 'Could not register device: Network error'), { cause: e })
} else if ((e as Error).name === 'InvalidStateError') {
throw new Error(t('settings', 'Could not register device: Probably already registered'), { cause: e })
}
throw new Error(t('settings', 'Could not register device'), { cause: e })
}
}
/**
* @param name Name of the device
* @param data Device attributes
*/
export async function finishRegistration(name: string, data: RegistrationResponseJSON) {
const url = generateUrl('/settings/api/personal/webauthn/registration')
const resp = await axios.post(url, { name, data: JSON.stringify(data) })
return resp.data
}
View on GitHub (pinned to ecdeb153ff)
When it happens
Trigger: Thrown at apps/settings/src/service/WebAuthnRegistrationSerice.ts:31 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of nextcloud/server@ecdeb153ff (2026-08-17).
Data as JSON: /api/errors/5c28ab1303c28798.
Report an issue: GitHub.