Changeset 3599:1bea61af9270
- Timestamp:
- 11/11/17 16:23:50 (8 years ago)
- Branch:
- 2.12
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
admin/install/index.php
r3557 r3599 186 186 $csp_prefix."'self' 'unsafe-inline'".$csp_suffix,'string','CSP style-src directive',true,true); 187 187 $blog_settings->system->put('csp_admin_img', 188 $csp_prefix."'self' data: media.dotaddict.org blob:",'string','CSP img-src directive',true,true);188 $csp_prefix."'self' data: http://media.dotaddict.org blob:",'string','CSP img-src directive',true,true); 189 189 190 190 # Add Dotclear version -
inc/admin/lib.dc.page.php
r3509 r3599 119 119 $csp_prefix."'self' 'unsafe-inline'".$csp_suffix; 120 120 $csp['img-src'] = $core->blog->settings->system->csp_admin_img ?: 121 $csp_prefix."'self' data: media.dotaddict.org blob:";121 $csp_prefix."'self' data: http://media.dotaddict.org blob:"; 122 122 123 123 # Cope with blog post preview (via public URL in iframe) -
inc/dbschema/upgrade.php
r3528 r3599 697 697 } 698 698 699 if (version_compare($version,'2.12.2','<')) 700 { 701 // SQlite Clearbricks driver does not allow using single quote at beginning or end of a field value 702 // so we have to use neutral values (localhost and 127.0.0.1) for some CSP directives 703 $csp_prefix = $core->con->driver() == 'sqlite' ? 'localhost ' : ''; // Hack for SQlite Clearbricks driver 704 705 # Update CSP img-src default directive 706 $strReq = 'UPDATE '.$core->prefix.'setting '. 707 " SET setting_value = '".$csp_prefix."''self'' data: http://media.dotaddict.org blob:' ". 708 " WHERE setting_id = 'csp_admin_img' ". 709 " AND setting_ns = 'system' ". 710 " AND setting_value = '".$csp_prefix."''self'' data: media.dotaddict.org blob:' "; 711 $core->con->execute($strReq); 712 } 713 699 714 $core->setVersion('core',DC_VERSION); 700 715 $core->blogDefaults();
Note: See TracChangeset
for help on using the changeset viewer.