SummerOfCode/2012/UserCSP/WeeklyUpdates/2012-05-21: Difference between revisions
< SummerOfCode | 2012 | UserCSP
Jump to navigation
Jump to search
| Line 10: | Line 10: | ||
* Database ("userCSP.sqlite") is created using third-party module "sqlite" for Jetpack. | * Database ("userCSP.sqlite") is created using third-party module "sqlite" for Jetpack. | ||
* To store user defined policies for web site "userCSPTable" is created "userCSP.sqlite" database. | * To store user defined policies for web site "userCSPTable" table is created in "userCSP.sqlite" database. | ||
* | * I modified the third-party "sqlite" module to operate on my custom database table. Such as "tableUsedOrNew" method is added to check whether "userCSPTable" table exits on user's computer or not. IF not then it create the table. | ||
* The "userCSPTable" contains 11 columns. domainName, defaultSrc, scriptSrc, objectSrc, imgSrc, mediaSrc, styleSrc, frameSrc, fontSrc , xhrSrc, frameAncestors. | * The "userCSPTable" contains 11 columns. domainName, defaultSrc, scriptSrc, objectSrc, imgSrc, mediaSrc, styleSrc, frameSrc, fontSrc , xhrSrc, frameAncestors. | ||
Revision as of 05:03, 22 May 2012
« previous week | index | next week »
This Week
Monday, 21 May
- Database ("userCSP.sqlite") is created using third-party module "sqlite" for Jetpack.
- To store user defined policies for web site "userCSPTable" table is created in "userCSP.sqlite" database.
- I modified the third-party "sqlite" module to operate on my custom database table. Such as "tableUsedOrNew" method is added to check whether "userCSPTable" table exits on user's computer or not. IF not then it create the table.
- The "userCSPTable" contains 11 columns. domainName, defaultSrc, scriptSrc, objectSrc, imgSrc, mediaSrc, styleSrc, frameSrc, fontSrc , xhrSrc, frameAncestors.
- The data type of each field in the table is "text", and the "domainName" is the primary key to retrieve and store CSP policies from database.