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

Feature Request - Minor Self Update at Runtime #3750

Open
1 task
amaitland opened this issue Aug 13, 2021 · 2 comments
Open
1 task

Feature Request - Minor Self Update at Runtime #3750

amaitland opened this issue Aug 13, 2021 · 2 comments
Assignees

Comments

@amaitland
Copy link
Member

I have yet to prove this is possible, so there is a chance this issue will be closed if it's deemed technically impossible.


For each major release there are a number of minor releases, usually these include an updated chromium version, often with security fixes. In theory there should be no breaking changes in these releases, so downloading and overriding the CefSharp/CEF dlls at runtime should be possible.

  • Manually test using minimal example

If the manual test is successful then there are a number of consideration

  • Versioning of old files to allow rollback
  • Write permissions
  • Update checks
  • Background downloading
  • Binary diff
@amaitland
Copy link
Member Author

For the full .Net Framework is appears that the C++/CLI dll requires a Binding Redirect to load correctly. The managed dlls don't appear to have a problem, just CefSharp.Core.Runtime.dll won't load correctly without a redirect for CefSharp.dll (it's only dependency).

<?xml version="1.0"?>
<configuration>
  <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2"/>
  </startup>

  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="CefSharp" publicKeyToken="40c4b6fc221f4138" culture="neutral" />
        <bindingRedirect oldVersion="93.1.111.0" newVersion="93.1.140.0" />
      </dependentAssembly>
    </assemblyBinding>
  </runtime>
</configuration>

So technically possible, this likely makes it impractical as rewriting the app.config at runtime would require permissions to do so.

I haven't tested with .Net Core/.Net 5.0 yet, the loader mechanism is different, so additional testing is required.

@amaitland
Copy link
Member Author

.Net Core 3.1 appears to be more promising, simply replacing the files without modifying the .deps.json file appears to work as expected for a Debug build, not sure if this will be different when it's published.

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

No branches or pull requests

1 participant