Payment iframe - the easiest way to insert Stripe into your website
paymentiframe.com
paymentiframe.com
Colin implemented this because besides credit card numbers, he was unwilling to give Stripe control over his website. Colin's users trust him with things that are much more sensitive than credit card numbers.
Interesting side note: Yes I know it's only meant to be a demonstration site but PAYMENTIFRAME.COM is using Google Analytics. Oh HAI GA...what's my Security Code again? Just needed a nice chuckle before I head back from lunch.
Myself, I'd place a lot of trust on cperciva, the former FreeBSD security officer, a guy who has written papers on security flaws in Pentium 4 processors. (http://www.daemonology.net/hyperthreading-considered-harmful...)
[edit] paymentiframe.com's FAQ now includes this:
Why should I trust you with my credit card entry form?
You probably shouldn't. This is more of a proof of concept — but you might also want to use the CGI script to generate an iframe which you download (along with the bits it links to) and serve up as a static file from a server you run (but make sure you get a separate domain name for it).
Sure, but you can just compare the two sites' external measures of security, and they're not even close.
Stripe domains:
- Pass optional HTTP security headers (like X-Frame-Options on manage.stripe.com)
- Are pinned to Chrome's HSTS list (http://src.chromium.org/viewvc/chrome?view=rev&revision=...) and pass a Strict-Transport-Security header
I feel like Colin built this little thingy to solve a real problem --- that by adding Stripe to his site, he was giving Stripe control over his site, and his site hosts information more sensitive than credit cards --- and people are piling on because his solution to his little problem doesn't solve every other imaginable security problem.
This would be less galling if the kinds of sites using Stripe today weren't almost uniformly rife with application security flaws that defeat most of the good intentions that Stripe has.
I frankly trust Colin Percival a lot more than I trust Olark. And I like Olark.
Your point is something Colin should address in his FAQ, and so it was good of you to make it, but it's also trivially knocked down.
So, you're saying that because Google Analytics could conceivably touch credit card information (using Stripe's JS), it's perfectly fine for some random guy with a suspect domain-name to?
I disagree.
I think this issue is LITERALLY this simple: people are accustomed to third-party applications that work by "just copy this tiny snippet of JS code into your layout template", and all the cool kids do it, so it's not up for discussion. But static content hosting a form in an iframe? THAT'S CRAZY TALK.
It surely gives food for thought.
Sourcing static content from a static web server run by a security expert in order to segregate your application's secrets from those of Stripe: TOTALLY IRRESPONSIBLE.
I am not endorsing the use of third-party JavaScript on someone's payment page. I am also not endorsing the use of serving your payment form inside of a third-party iframe hosted on paymentiframe.com. I am not sure why you consider this opinion to be false.
It sure does make the argument simpler to pretend that you can just keep the Olark and Typekit and Optimizer bugs off your payments page and call it a day, but that doesn't actually do anything to protect most sites. Engage instead with my actual argument, which is that for virtually every app using these services, bugging your front page with Olark is even more unsafe than this iframe is.
As in, even if the "evil script" set it's domain to yourdomain.com, unless your pages on yourdomain.com ALSO do
document.domain = 'yourdomain.com';
The script on the subdomain can't access that content.
[EDIT] Whoever is downvoting this, can you demonstrate otherwise?
It's also crazy enough that I wouldn't want to trust that every browser in the world will always share that same behaviour.
http://www.whatwg.org/specs/web-apps/current-work/multipage/...
Listen, if you don't trust Stripe's JavaScript, just use their HTTP API instead from your server: https://stripe.com/docs/api
The best answer is "don't link to Javascript URLs that you don't control and audit on your website". Nobody likes that answer, but that doesn't make the second-best answer any more meaningful.
Exactly. There's no way I would be serving up third party javascript to a logged-in Tarsnap user, even inside an iframe, if it weren't for the fact that dealing with PCI auditing would irreparably damage my sanity.
Technically, the iframe is dynamic content, seeing as it's generated by a CGI script based on the parameters in the URL. :-)
And asking customers to enter their CC details on your domain doesn't break this rule?
> a form will be submitted to your server with a stripe_token for you to process
I'm assuming it just sends the Stripe token, and not CC info? If it does send CC info, I assume it's compliant with all the laws and regulations in every country?
It doesn't break that rule for me. It is a reason why other Stripe users might want to think twice before using the iframe I host, of course.
I'm assuming it just sends the Stripe token, and not CC info?
Yes.
Well that's the point really. You say that a "basic principle of security" is to "avoid trusting people unnecessarily" which is exactly what this service you have created is asking people to do.
I love Stripe, I love people hacking and creating new cool things but an emerging trend I'm seeing with Stripe is that people are really not taking the security of the CC numbers their customers have entrusted to them as cautiously and as securely as they should.
I'm trusting people to decide which risks they want to take -- I'm providing tools, not dictating policy.
I think it's obvious to most people here, but Stripe's targeted at essentially everyone. It's quite possible that someone'd stumble across your site who just learned PHP and goes "sounds good, I'll drop it in".
I'm not sure that someone would be automatically wrong to do that. People should be aware that using paymentiframe.com means trusting me to not steal their customers' credit cards and trusting me to keep the site secure, but if someone makes an informed decision to place that trust in me, I can't say that they're necessarily wrong to do so.
As I said: Tools, not policy.
In fact, their tutorials are so well written and their signup so frictionless that I'd say that any interested website creator should have little trouble setting up a form actually using stripe instead of an iframe.
By using an iframe you make sure that they do not get access to any information on your page - much less the users session cookie.
Instead, if you use this service, you're trusting another 3rd party site to be available and to not be compromised.
I know it is shocking to many of you to hear this, but the data Stripe collects is not really the most sensitive information on the Internet.
The point of the iframe is to contain the damage from any possible compromise. If PAYMENTIFRAME.COM is insecure (heh), you still aren't going to lose user sessions to your actual application.
https://www.owasp.org/index.php/Cross_Frame_Scripting
> Every key press the browser user makes in the example.com frame, while trying to log into example.com, can be captured by the attacker, and reported back to evil.com.
But this is irrelevant - user can't verify if the domain of the iframe is trusted. If the attacker can modify the parent frame javascript he can just replace the iframe with a phishing page.
Not that it's terribly hard to build a stripe-compatible form...
That would defeat the protection which the Same Origin policy gives you (since the iframe would have the same origin as the rest of your site).
or that stripe would host the service themselves
Yes, that would be much better.
At the expense of loading third party javascript directly into their pages, you mean?
So, one of two things is true:
-- Paymentiframe/tarsnap is a PCI DSS compliant third party
-- the merchant is intentionally violating the PCI DSS rules by sending credit card data to you
So, which is it?
The change for that paymentiframe.com get comprimised I see is way higher, than Stripe is getting comprimised.
We'll have to agree to disagree about that. Not that there's anything wrong with Stripe's security, but I know a little bit about the subject too. :-)
Ignoring all those extra fees and charges unrelated to a single payment, Authorize.net charges 2.19% + $0.27 in the best case (qualified domestic Visa). In the worst case (non-qualified international MasterCard), they charge 4.49% + $0.2685.
Even only considering the best case, Stripe's 2.9% + $0.30 doesn't seem 'ripoff' to me.
Offering to host this seems like a really bad idea.
I know you're well meaning and trustworthy, but this shouldn't be run by a third party. For long term reliability reasons as much as security.