Couldn't one circumvent CSP by sending the data to a legitimate analytics service that everyone uses like Google Analytics?
This is why, when I recently built a credit card form, we didn't include any trackers or third-party code (beyond our vendor's). No dependencies at all—our vendor also has no dependencies in the JS we use to implement the CC form. That did mean no jQuery, no Google Analytics, no NPM modules and we had to build it as a standalone page outside our React setup, but it's worth it to be able to definitively inspect every…
Harvesting credit card numbers and passwords from websites
111–120 of 128 posts
Re: Harvesting credit card numbers and passwords from websites
#112> Our penetration testers would see it in their HTTP request monitoring tools! > What hours do they work? My code doesn’t send anything between 7am and 7pm. Which Time Zone? Hah! (Not that this one nit pick takes away from the general very well made point of the article, I just love how TimeZone problems infect everything )
Of course, we all do this. /sarcasm
Re: Harvesting credit card numbers and passwords from websites
#113Earlier quoted context omitted.
Nobody is singling out NPM. The issue is the current JavaScript ecosystem and that happens to be provided through NPM, so you can use "NPM" as a shorthand for "the way JavaScript developers these days use NPM to depend on a gazillion trivial packages with totally unknown provenance".
why not just say "excessive dependencies" and be correct, succinct and perfectly clear?
The next problem is that npmjs is "free for all". Imagine anyone could easily add new packages to the debian repo. Sure, I don't expect the debian folks to audit every new addition or update to existing packages, but there is at least some chain of trust, plus there is some incentive to not have malware ridden packages in your distro because it hurts your credibility. A distro is both, an infrastructure and content provider. npmjs is just the infrastructure, so it takes some more messups for people to consider moving away from it.
Re: Harvesting credit card numbers and passwords from websites
#114One of the biggest problems here is that there is no “chain of custody” from Github source to uploaded NPM module; otherwise one of the developers using the malicious package could have audited the source code before including it in their own code. ‘npm publish’ would ideally insist on reproducible builds, enforce this by minifying or compiling packages itself, and finally encourage the community to always audit the…
Even if you had that, no one is going to inspect all that code. npm is a cluster-farkle of insane amounts of packages. The whole point of the article is you should implement CSP.
Re: Harvesting credit card numbers and passwords from websites
#115Couldn't one circumvent CSP by sending the data to a legitimate analytics service that everyone uses like Google Analytics?
This is why, when I recently built a credit card form, we didn't include any trackers or third-party code (beyond our vendor's). No dependencies at all—our vendor also has no dependencies in the JS we use to implement the CC form. That did mean no jQuery, no Google Analytics, no NPM modules and we had to build it as a standalone page outside our React setup, but it's worth it to be able to definitively inspect every…
Re: Harvesting credit card numbers and passwords from websites
#116Re: Harvesting credit card numbers and passwords from websites
#117Re: Harvesting credit card numbers and passwords from websites
#118Couldn't one circumvent CSP by sending the data to a legitimate analytics service that everyone uses like Google Analytics?
This is why, when I recently built a credit card form, we didn't include any trackers or third-party code (beyond our vendor's). No dependencies at all—our vendor also has no dependencies in the JS we use to implement the CC form. That did mean no jQuery, no Google Analytics, no NPM modules and we had to build it as a standalone page outside our React setup, but it's worth it to be able to definitively inspect every…
Re: Harvesting credit card numbers and passwords from websites
#119Couldn't one circumvent CSP by sending the data to a legitimate analytics service that everyone uses like Google Analytics?
This is why, when I recently built a credit card form, we didn't include any trackers or third-party code (beyond our vendor's). No dependencies at all—our vendor also has no dependencies in the JS we use to implement the CC form. That did mean no jQuery, no Google Analytics, no NPM modules and we had to build it as a standalone page outside our React setup, but it's worth it to be able to definitively inspect every…
Re: Harvesting credit card numbers and passwords from websites
#120I'm sometimes frustrated by uMatrix blocking every requests to third party website and forcing me to accept each of them when needed. But when I see exploits like this I'm happy that I haven't uninstalled it :D. You still have to be vigilant when whitelisting requests in the uMatrix panel though.
It also depends on the page you are visiting. If it's just some random post on net I actually don't care much if they do manage to post data elsewhere (the risk in that case is actually higher if I allow ajax.googleapis.com than some random non-google page), but with banking sites and credit card forms you need to be careful.