Open Bug 1911101 Opened 2 years ago Updated 7 months ago

Support all DOM strings as IDB database file names

Categories

(Core :: Storage: IndexedDB, defect, P4)

defect

Tracking

()

ASSIGNED
Tracking Status
firefox130 --- affected

People

(Reporter: jari, Assigned: jari)

References

Details

Attachments

(3 files)

According to specification, any DOMString should work as an IndexedDB database name but the current implementation is limited to unicode strings. To fix this, it should be ensured that

  • the existing database names on disk are still found (i.e. old names keep working) and the databases() API support is not broken (listing the databases considers both old and new names)
  • data migration can kept minimal (or avoided altogether) to not hit the memory limits or long waits that appear like hangs for old profiles.

Users can enter any byte combination as a database name but not all
combinations are valid unicode text. The database names are only stored
in the database itself and there is no master record which could be used
to map a non-textual name to a file. Therefore, we use an encoding of a
non-unicode name as the file name. In this patch, we introduce the
DatabaseFileName type to prevent mixing up the two names.

Assignee: nobody → jjalkanen
Status: NEW → ASSIGNED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: