Disclosure Statement: This site contains affiliate links, which means that I may receive a commission if you make a purchase using these links. As an eBay Partner, I earn from qualifying purchases.

Login Issue with Google Chrome using CEF4Delphi

Post Reply
luiz_antoniosp
Posts: 8
Joined: Sat Jun 24, 2023 5:28 am

Login Issue with Google Chrome using CEF4Delphi

Post by luiz_antoniosp »

Hello Community,

I am facing a challenge with automating the login process for Google Chrome using CEF4Delphi. I have developed an application that utilizes CEF4Delphi for web interactions, including logging into websites. However, when attempting to log into Google Chrome, I encounter an issue. Google Chrome seems to block logins from browsers that it does not recognize as secure.

Problem Details:

Error Message: "Cannot log in. This browser or app may not be secure."
Possible Causes:
Google may block logins from browsers lacking JavaScript support or having JavaScript disabled.
Insecure or incompatible extensions added to the browser can trigger security concerns.
Browsers controlled by software automation instead of human interaction may be blocked.
Browsers embedded within a different application can face restrictions.
Attempts Made:
I have tried setting a custom user agent using CEF4Delphi to emulate Google Chrome.
I have explored different methods within CEF4Delphi to interact with Google Chrome, but the login issue persists.
Request for Assistance:
Has anyone encountered a similar problem with Google Chrome login automation using CEF4Delphi?
Are there specific settings, headers, or techniques that have proven effective in bypassing Google's security restrictions?
Any insights or guidance on resolving this issue would be greatly appreciated.
Additional Information:

CEF4Delphi Version: [Specify your version]
Operating System: [Your OS details]
I have already reviewed Google's recommendations regarding browser compatibility and JavaScript activation, but the problem persists. If anyone has successfully tackled a similar challenge or has suggestions on resolving this, please share your insights. Thank you in advance for your assistance.

Best regards,
User avatar
salvadordf
Posts: 4057
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: Login Issue with Google Chrome using CEF4Delphi

Post by salvadordf »

Hi,

Please, read this issue :
https://github.com/salvadordf/CEF4Delphi/issues/443

Try using a CEF browser in "Chrome runtime" mode but remember that the CEF project maintainer considers this mode in experimental state. Some features are not implemented or don't work as expected.

Open the MiniBrowser demo and enable this line :
https://github.com/salvadordf/CEF4Delphi/blob/9c94220a5dd868654b2f2dd0fbd7fd56ed72330d/demos/Delphi_VCL/MiniBrowser/uMiniBrowser.pas#L306

Then run the demo and try to login.
luiz_antoniosp
Posts: 8
Joined: Sat Jun 24, 2023 5:28 am

Re: Login Issue with Google Chrome using CEF4Delphi

Post by luiz_antoniosp »

Hi,
I want to thank you for your help, as your suggestion was very useful, which worked, however the factor that I need most I am finding it difficult to find a solution: I successfully installed some extensions in Google Chrome, but the extension that I need most, I can't install it, see what Google says: "This item is not compatible with your current version of Chrome" >Button Click >> "Update Chrome" however this extension is installed perfectly on Google installed on Windows10, another factor If I click on update Crhome it updates the chrome that is installed on win10. Follow the extension: https://chromewebstore.google.com/detail/huboh-inteligencia-artifi/koljjobchnballpddmocijkkofgefceb?hl=pt-br
User avatar
salvadordf
Posts: 4057
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: Login Issue with Google Chrome using CEF4Delphi

Post by salvadordf »

I have limited experience installing extensions in CEF browsers but remember that :
  • The "Chrome runtime" mode is in experimental state and some issues might be caused by an incomplete implementation.
  • Some extensions require parts of the Chromium user interface. Try installing that extension using the TinyBrowser2 demo which uses that user interface.
I would also recommend using the latest CEF4Delphi version available at GitHub.
https://github.com/salvadordf/CEF4Delphi/archive/master.zip
Post Reply