You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
One of the libs used thoughout the sdk UriUtil.cpp, the UriProtocol function takes a LPCWSTR and sets an out param that is a URI_PROCOTOL enum. It is comparing specific characters without consideration for case. Specifically the comparison for an HTTPS uri is testing for "httpS".
The expected result of this function should be to compare and match the scheme section of a Uri without regard to case and not compare in a manner where it may access outside the bounds of the given string.
This bug was found by creating a bundle installer with a .NET prereq using the BalExtension, then overriding the WixMbaPrereqLicenseUrl to a value that started with "https://". At runtime a link is shown in the installer, but clicking on the link produces the Error 0x80070002: Failed to launch URL to EULA.
Originally opened by amoravec
The text was updated successfully, but these errors were encountered:
We evaluated the out of bounds concern raised in this bug and that is not an issue as long as the strings are null terminated (the SAL annotation on the function suggests they should be). Each character evaluation is AND'd together so if the string is "too short" the null character (\0) will be evaluated and short circuit any remaining evaluations outside of the bounds of the string.
However, the title of the bug is correct. The UriProtocol function in uriutil.cpp is case sensitive.
@firegiant, You are absolutely correct about the null terminated string being short-circuited in the comparison. I've updated the description accordingly to avoid further confusion.
One of the libs used thoughout the sdk UriUtil.cpp, the UriProtocol function takes a LPCWSTR and sets an out param that is a URI_PROCOTOL enum. It is comparing specific characters without consideration for case. Specifically the comparison for an HTTPS uri is testing for "httpS".
The expected result of this function should be to compare and match the scheme section of a Uri without regard to case and not compare in a manner where it may access outside the bounds of the given string.
This bug was found by creating a bundle installer with a .NET prereq using the BalExtension, then overriding the WixMbaPrereqLicenseUrl to a value that started with "https://". At runtime a link is shown in the installer, but clicking on the link produces the Error 0x80070002: Failed to launch URL to EULA.
The text was updated successfully, but these errors were encountered: