Skip to content

Instantly share code, notes, and snippets.

@tfennelly
Last active August 29, 2015 14:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tfennelly/b8b6dffe7718418314be to your computer and use it in GitHub Desktop.
Save tfennelly/b8b6dffe7718418314be to your computer and use it in GitHub Desktop.
// From CopyArtifact plugin - CopyArtifact.java line 271: http://goo.gl/ob2HAo
if (job != null && !expandedProject.equals(project)
// If projectName is parameterized, need to do permission check on source project.
&& !canReadFrom(job, build)) {
job = null; // Disallow access
}
if (job != null && (!(expandedProject.equals(project)
|| !canReadFrom(job, build))) {
job = null; // Disallow access
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment