[edk2-devel] Need clarification about UEFI Strings

Pedro Falcato pedro.falcato at gmail.com
Tue Jun 7 07:43:32 UTC 2022


Hi Ayush,

In the latest UEFI 2.9 spec, it's specified under 2.3.1 that CHAR8
strings/characters are (usually) ASCII, and CHAR16 strings/characters are
(usually) UCS-2 (*not* UTF-16).

On Tue, Jun 7, 2022 at 7:02 AM Ayush Singh <ayushdevel1325 at gmail.com> wrote:

> Hello everyone, I am trying to write an implementation for UEFI
> strings in Rust and just wanted clarification about some things.
>
> Are UEFI Strings UTF-16 encoded? I have looked at some previous Rust
> implementations for this and it seems UEFI does not support the whole
> UTF-16 but rather only UCS-2
> (https://en.wikipedia.org/wiki/Universal_Coded_Character_Set) which is
> a subset of UTF-16.
>
> There is also something called WTF-8
> (https://en.wikipedia.org/wiki/UTF-8#WTF-8) which Rust uses to
> represent OsStrings in Windows which is supposed to use UTF-16 (?).
>
> Anyway, if someone can point me to the resources/specifications of
> UEFI Strings, it would be a great help.
>
> Ayush Singh
>
>
> 
>
>
>

-- 
Pedro Falcato


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#90278): https://edk2.groups.io/g/devel/message/90278
Mute This Topic: https://groups.io/mt/91595087/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/edk2-devel-archive/attachments/20220607/be84512d/attachment.htm>


More information about the edk2-devel-archive mailing list