mirror of
https://github.com/Termix-SSH/Termix.git
synced 2026-10-28 14:15:24 +00:00
20 lines
748 B
SQL
20 lines
748 B
SQL
-- webauthn 0001: adopt_webauthn_credentials
|
|
-- Generated by termix-plugin migrations. Review before committing.
|
|
|
|
CREATE TABLE IF NOT EXISTS `webauthn_credentials` (
|
|
`id` varchar(255) PRIMARY KEY NOT NULL,
|
|
`user_id` varchar(255) NOT NULL,
|
|
`name` text NOT NULL,
|
|
`credential_id` varchar(255) NOT NULL UNIQUE,
|
|
`public_key` text NOT NULL,
|
|
`counter` int NOT NULL DEFAULT 0,
|
|
`device_type` text,
|
|
`backed_up` boolean NOT NULL DEFAULT false,
|
|
`transports` text,
|
|
`user_verification` text NOT NULL DEFAULT ('preferred'),
|
|
`created_at` text NOT NULL DEFAULT (CURRENT_TIMESTAMP),
|
|
`last_used_at` text,
|
|
FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE
|
|
);
|
|
RENAME TABLE `webauthn_credentials` TO `p_webauthn_credentials`;
|