Skip to content

Commit

Permalink
Merge pull request #9 from oleg-nenashev/bug/JENKINS-44965
Browse files Browse the repository at this point in the history
[JENKINS-44965] - Restrict the direct access to EnvInjectAction#envMap
  • Loading branch information
oleg-nenashev committed Jun 22, 2017
2 parents 0aa6ccd + db57fc3 commit 9e9ded8
Showing 1 changed file with 8 additions and 0 deletions.
Expand Up @@ -16,6 +16,8 @@
import javax.annotation.CheckForNull;
import javax.annotation.Nonnull;
import jenkins.model.RunAction2;
import org.kohsuke.accmod.Restricted;
import org.kohsuke.accmod.restrictions.NoExternalUse;

/**
* @author Gregory Boissinot
Expand All @@ -24,6 +26,12 @@ public class EnvInjectAction implements RunAction2, StaplerProxy {

public static final String URL_NAME = "injectedEnvVars";

/**
* Local cache of environment variables.
* This cache may be null if the loading has never been performed.
* Use {@link #getEnvMap()} in external API
*/
@Restricted(NoExternalUse.class)
protected transient @CheckForNull Map<String, String> envMap;

private transient @Nonnull Run<?, ?> build;
Expand Down

0 comments on commit 9e9ded8

Please sign in to comment.