Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<Img> tag with a custom protocol and tilde symbol in URI in the source attribute crashes application #2047

Closed
gribunin opened this issue May 15, 2017 · 1 comment
Labels

Comments

@gribunin
Copy link

gribunin commented May 15, 2017

  • What version of the product are you using?
    Master branch from git, also reproduced in Nuget ver. 57.0.0

  • What architecture x86 or x64?
    Reproduced in x64. The x86 architecture I haven't tested.

  • On what operating system?
    Win7

  • Are you using WinForms, WPF or OffScreen?
    WinForms

  • What steps will reproduce the problem?
    I am trying to open HTML file which contains <img> tag with a source attribute, which points to a resource with a custom protocol and URL containing "tilde" symbol (~). Minimal HTML example is the following:

<html>
<img src="ns://t~est.html">
</html>
  • What is the expected output? What do you see instead?
    Expected the application rendering a broken image if a custom protocol is not registered or calling methods of the registered custom protocol handler if it exists. Instead the application just crashes.

  • Please provide any additional information below.
    In the log generated by CEF I see only the following message which seems to be related to the problem:
    bad message 1507679 terminating renderer.
    If the application has a registered factory for this custom protocol, its methods are not called before crash for this URL.

  • Does this problem also occur in the CEF Sample Application from http://opensource.spotify.com/cefbuilds/index.html?
    I am not able to reproduce the bug using cefclient. I tested with cef_binary_3.3029.1619

@gribunin gribunin changed the title Img tag with a custom protocol in tilde symbol in URI in the source attribute crashes application <Img> tag with a custom protocol and tilde symbol in URI in the source attribute crashes application May 15, 2017
@merceyz
Copy link
Member

merceyz commented May 15, 2017

ns://t~est.html

This is not a valid URI

A valid version would be ns://example/t~est.html

Adding this { "/t~est.html", "Test" } to the CefSharpSchemeHandlerFactory and <img src="custom://cefsharp/t~est.html"> to any file works

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants