Skip to content

Bug: styleSrcElem and scriptSrcElem are not updated with th nonce #9992

Description

@Juju86

PHP Version

8.3

CodeIgniter4 Version

4.7.0

CodeIgniter4 Installation Method

Composer (using codeigniter4/appstarter)

Which operating systems have you tested for this bug?

Windows

Which server did you use?

apache

Environment

development

Database

/

What happened?

styleSrcElem and scriptSrcElem are not updated with th nonce.

Steps to Reproduce

turn app.CSPEnabled to true in dev.

Expected Output

system / HTTP / ContentSecurityPolicy.php
Add $this->addScriptSrcElem('nonce-' . $this->scriptNonce); in getScriptNonce().
And $this->addStyleSrcElem('nonce-' . $this->styleNonce); in getStyleNonce().

Anything else?

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugVerified issues on the current code behavior or pull requests that will fix them

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions