Skip to content

Commit

Permalink
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 19, 2017
1 parent 0aa6ccd commit db57fc3
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 db57fc3

Please sign in to comment.