Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-71513

[core] CSP compatibility: eval call in hudson-behaviour.js (renderOnDemand)

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • core
    • 2.447

        [JENKINS-71513] [core] CSP compatibility: eval call in hudson-behaviour.js (renderOnDemand)

        Yaroslav Afenkin created issue -

        This is a part of Stapler, so addressing this does not seem straightforward to me.

        See:

        At glance it might be possible to not build the makeStaplerProxy(...) call as string, but to assign separate attributes to an element, and then call makeStaplerProxy in JS in core instead of eval("makeStaplerProxy(...)"), but it requires deeper investigation.

        Yaroslav Afenkin added a comment - This is a part of Stapler, so addressing this does not seem straightforward to me. See: https://github.com/jenkinsci/stapler/blob/7790f4fa2f5d027a71ea19a1327013a3b852e087/core/src/main/resources/org/kohsuke/stapler/bind.js#L5   https://github.com/jenkinsci/stapler/blob/7790f4fa2f5d027a71ea19a1327013a3b852e087/core/src/main/java/org/kohsuke/stapler/bind/Bound.java#L66 At glance it might be possible to not build the makeStaplerProxy(...) call as string, but to assign separate attributes to an element, and then call makeStaplerProxy in JS in core instead of eval("makeStaplerProxy(...)") , but it requires deeper investigation.
        Yaroslav Afenkin made changes -
        Status Original: Open [ 1 ] New: In Progress [ 3 ]
        Yaroslav Afenkin made changes -
        Status Original: In Progress [ 3 ] New: Open [ 1 ]
        Daniel Beck made changes -
        Summary Original: [core] CSP compatibility: eval call in hudson-behaviour.js New: [core] CSP compatibility: eval call in hudson-behaviour.js (renderOnDemand)
        Daniel Beck made changes -
        Assignee New: Daniel Beck [ danielbeck ]
        Daniel Beck made changes -
        Status Original: Open [ 1 ] New: In Progress [ 3 ]
        Daniel Beck made changes -
        Status Original: In Progress [ 3 ] New: In Review [ 10005 ]
        Daniel Beck made changes -
        Remote Link New: This issue links to "PR#6865 (Web Link)" [ 28864 ]
        Alexander Brandes made changes -
        Released As New: 2.447
        Resolution New: Fixed [ 1 ]
        Status Original: In Review [ 10005 ] New: Closed [ 6 ]

          danielbeck Daniel Beck
          yafenkin Yaroslav Afenkin
          Votes:
          0 Vote for this issue
          Watchers:
          1 Start watching this issue

            Created:
            Updated:
            Resolved: