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

CORS blocked #2

Closed
EnumC opened this issue Jul 25, 2017 · 2 comments
Closed

CORS blocked #2

EnumC opened this issue Jul 25, 2017 · 2 comments

Comments

@EnumC
Copy link

EnumC commented Jul 25, 2017

Hi! I am implementing the service on a webapp, but my requests aren't getting through due to the lack of 'Access-Control-Allow-Origin' header on the api. Is this intended or simply skipped? Thanks!

XMLHttpRequest cannot load https://check.getipintel.net/check.php?ip=this_is_an_ip&contact=this_is_an_email_address&format=json. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:4200' is therefore not allowed access.

@blackdotsh
Copy link
Owner

Hi,
This is intended. We strongly discourage users from implementing API queries on client side because

  • From a security's perspective, you should not trust input from a client. You cannot be sure that the client is running legitimate API queries to our API and returning the result that's unmodified.

  • We impose limitations on our free API. If it's implemented client side then one cannot control the exact amount of queries sent to our API. If you go on a custom plan which gives you a unique custom subdomain, then all the clients would know this information and abuse your custom subdomain.

@EnumC
Copy link
Author

EnumC commented Jul 25, 2017

I thought I could just stick it in my angular project, but I guess that wouldn't work. Thanks for the explanation.

@EnumC EnumC closed this as completed Jul 25, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants