提交 cfa7be10 编写于 作者: R Ryan Campbell

Rename EXECUTE_SCRIPT to RUN_SCRIPTS

上级 6b5c4436
......@@ -70,7 +70,7 @@ public class GroovyCommand extends CLICommand implements Serializable {
protected int run() throws Exception {
// this allows the caller to manipulate the JVM state, so require the execute script privilege.
Jenkins.getInstance().checkPermission(Jenkins.EXECUTE_SCRIPT);
Jenkins.getInstance().checkPermission(Jenkins.RUN_SCRIPTS);
Binding binding = new Binding();
binding.setProperty("out",new PrintWriter(stdout,true));
......
......@@ -3126,7 +3126,7 @@ public class Jenkins extends AbstractCIBase implements ModifiableItemGroup<TopLe
private void doScript(StaplerRequest req, StaplerResponse rsp, RequestDispatcher view) throws IOException, ServletException {
// ability to run arbitrary script is dangerous
checkPermission(EXECUTE_SCRIPT);
checkPermission(RUN_SCRIPTS);
String text = req.getParameter("script");
if (text != null) {
......@@ -3622,7 +3622,7 @@ public class Jenkins extends AbstractCIBase implements ModifiableItemGroup<TopLe
public static final PermissionGroup PERMISSIONS = Permission.HUDSON_PERMISSIONS;
public static final Permission ADMINISTER = Permission.HUDSON_ADMINISTER;
public static final Permission READ = new Permission(PERMISSIONS,"Read",Messages._Hudson_ReadPermission_Description(),Permission.READ,PermissionScope.JENKINS);
public static final Permission EXECUTE_SCRIPT = new Permission(PERMISSIONS, "ExecuteScript", Messages._Hudson_ExecuteScriptPermission_Description(),ADMINISTER,PermissionScope.JENKINS);
public static final Permission RUN_SCRIPTS = new Permission(PERMISSIONS, "RunScripts", Messages._Hudson_RunScriptsPermission_Description(),ADMINISTER,PermissionScope.JENKINS);
/**
* {@link Authentication} object that represents the anonymous user.
......
......@@ -143,8 +143,8 @@ Hudson.ReadPermission.Description=\
This permission is useful when you don''t want unauthenticated users to see \
Jenkins pages &mdash; revoke this permission from the anonymous user, then \
add "authenticated" pseudo-user and grant the read access.
Hudson.ExecuteScriptPermission.Description=\
The "execute script" permission is necessary for running groovy scripts \
Hudson.RunScriptsPermission.Description=\
The "run scripts" permission is necessary for running groovy scripts \
via the groovy console or groovy cli command.
Hudson.NodeDescription=the master Jenkins node
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册