Skip to content

Commit bcc7fb2

Browse files
selvanaircron2
authored andcommitted
Set UTF-8 as the codepage using manifest declaration
Works on Windows 10+. This ensures any UTF-8 string we pass to ANSI API will not get interpreted in some local code page in effect at runtime. Although we do not use any such API, OpenSSL dll we link to does (e.g., the store API used for reading certificate and key from files). OpenSSL may fix this in future versions, but this is an easy workaround that looks harmless and appropriate. Fixes failure to read certificates when filenames contain non-ascii characters reported by: Carsten Mietzsch <[email protected]> Ref: https://learn.microsoft.com/en-us/windows/apps/design/globalizing/use-utf8-code-page Github: #920 Change-Id: Ic4e233c788b16a862c1fddcf314a3da661072fb5 Signed-off-by: Selva Nair <[email protected]> Acked-by: Lev Stipakov <[email protected]> Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1413 Message-Id: <[email protected]> URL: https://www.mail-archive.com/[email protected]/msg34805.html Signed-off-by: Gert Doering <[email protected]>
1 parent 31ef3d6 commit bcc7fb2

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/openvpn/openvpn.manifest

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@
1414
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/>
1515
</application>
1616
</compatibility>
17+
<application>
18+
<windowsSettings>
19+
<activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
20+
</windowsSettings>
21+
</application>
1722
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
1823
<security>
1924
<requestedPrivileges>

0 commit comments

Comments
 (0)