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

FR: Support CAPTCHA library #19976

Closed
leonahliang90 opened this issue Dec 19, 2018 · 9 comments
Closed

FR: Support CAPTCHA library #19976

leonahliang90 opened this issue Dec 19, 2018 · 9 comments

Comments

@leonahliang90
Copy link
Contributor

Describe the new feature or change to an existing feature you'd like to see

Hi @kristoferbaxter , in order to deal with Crawlers as we stated in #19580 , we would need to include some js library provided by the security team. Is there a way that we can import third js library into AMP page please ?

Describe alternatives you've considered

None

Additional context

https://user-images.githubusercontent.com/4065175/49558944-dd900e80-f947-11e8-96b5-ecdc4e8ebd29.gif

@aghassemi
Copy link
Contributor

@leonalicious depends, would the script be able to run and do its thing inside a web worker? we are not planning to allow 3P JS run in the same context as the AMP page, but rather sandboxed in a worker and communicating with the page through WorkerDom, which is exposed as amp-script.

/to @choumx

@leonahliang90
Copy link
Contributor Author

leonahliang90 commented Dec 20, 2018

thank you for the prompt solution, sounds legit, please spare me some time to double confirm this with our security team and I will get back to you. But regard the amp-script, if i remember it correctly it should be rolling out somewhere at the Q1 of 2019 right ?

@ampprojectbot ampprojectbot modified the milestones: Pending Triage, New FRs Jan 9, 2019
@ampprojectbot
Copy link
Member

This issue doesn't have a category which makes it harder for us to keep track of it. @choumx Please add an appropriate category.

@dreamofabear
Copy link

@leonalicious Which browser APIs does this robot-detection script depend on? amp-script is based on worker-dom, which only supports a subset of available APIs.

Would putting the script in an amp-iframe work? We also have a new component for a similar feature in amp-recaptcha.

@dreamofabear dreamofabear changed the title FR: import third party library js into AMP Page FR: Support CAPTCHA library Jan 9, 2019
@leonahliang90
Copy link
Contributor Author

Based on what I can tell from what we are missing is navigator.

amp-iframe is something async and I personally think it will not work, maybe worth to give a try

@dreamofabear
Copy link

Cool, let us know if amp-iframe doesn't work!

@torch2424
Copy link
Contributor

Hello!

What is the status of this? Can I close this in favor of consolidating all reCAPCTHA issues into #2273 ? Or is this not realated to amp-recaptcha-input?

Thank you! 😄

@torch2424
Copy link
Contributor

Closing this in favor of #2273 . Please feel free to comment to get this re-opened if this does not support your use case. Thanks! 😄

@torch2424
Copy link
Contributor

Hello,

Sorry to reply on an old issue, but in case anyone gets here from a search engine, just want to say this was implemented in #2273 .

See my comment here for getting started: #2273 (comment)

Thanks! 😄

cc @leonalicious

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

5 participants