s3 urls have the following pattern:
http(s)://s3.amazonaws.com/{app}/{resource}
perhaps other CDNs use something similar. In this case it's meaningless to grant trust to the domain since it's just a container of many apps from many customers. Site Specific Permissions Policy would mitigate this, but still it would be better to trust the {app} and not the whole domain, even in a site specific scenario. How feasible is this?
per dir trust for amazon s3 and other CDN hosted scripts
per dir trust for amazon s3 and other CDN hosted scripts
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6
- Giorgio Maone
- Site Admin
- Posts: 9527
- Joined: Wed Mar 18, 2009 11:22 pm
- Location: Palermo - Italy
- Contact:
Re: per dir trust for amazon s3 and other CDN hosted scripts
Currently it's not (the whole browser security model is per-site, rather than per-path).al_9x wrote:How feasible is this?
However you can do some fine tuning with ABE.
Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6
Re: per dir trust for amazon s3 and other CDN hosted scripts
There are no paths, there is only a part of the URI that resembles paths. It's up to the web server how to handle this.
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.2) Gecko/20100115 Firefox/3.6
- Giorgio Maone
- Site Admin
- Posts: 9527
- Joined: Wed Mar 18, 2009 11:22 pm
- Location: Palermo - Italy
- Contact:
Re: per dir trust for amazon s3 and other CDN hosted scripts
Not sure about what you mean here. From the browser's standpoint, they're paths (the browser can't tell what they mean to the server, e.g. if they point to actual filesystem resources or they trigger some application action through URL rewriting).dhouwn wrote:There are no paths, there is only a part of the URI that resembles paths. It's up to the web server how to handle this.
Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6
Re: per dir trust for amazon s3 and other CDN hosted scripts
I find Using ABE to selectively grant access to s3 is like using RequestPolicy without the convenience of its UI. This really needs a better approach, like Site Specific Permissions Policy.Giorgio Maone wrote:However you can do some fine tuning with ABE.
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6
Re: per dir trust for amazon s3 and other CDN hosted scripts
Would it be possible to just add some specific rules for s3 / cloudfront / etc.. (the most common CDN's) that was something along the lines of:
If top level domain is whitelisted, then trust all CDN's - Else, dont.
Additionally, perhaps we can treat the s3 domains as partial urls ( http://s3.amazonaws.com/customer/ gets white listed, instead of just s3.amazonaws.com )
So basically if I am browsing twitter.com. any CDN that trys to load scripts on twitter.com would be allowed (provided i have given permissions to twitter.com )
If top level domain is whitelisted, then trust all CDN's - Else, dont.
Additionally, perhaps we can treat the s3 domains as partial urls ( http://s3.amazonaws.com/customer/ gets white listed, instead of just s3.amazonaws.com )
So basically if I am browsing twitter.com. any CDN that trys to load scripts on twitter.com would be allowed (provided i have given permissions to twitter.com )
Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.12) Gecko/20101026 Firefox/3.6.12