Skip to content

Commit f8f61c1

Browse files
author
Koji Noguchi
committed
PIG-5352: Please add OWASP Dependency Check to the build ivy.xml (knoguchi)
git-svn-id: https://svn.apache.org/repos/asf/pig/trunk@1872609 13f79535-47bb-0310-9956-ffa450edef68
1 parent 4191344 commit f8f61c1

File tree

4 files changed

+30
-1
lines changed

4 files changed

+30
-1
lines changed

CHANGES.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ PIG-5282: Upgade to Java 8 (satishsaley via rohini)
2626

2727
IMPROVEMENTS
2828

29+
PIG-5352: Please add OWASP Dependency Check to the build ivy.xml (knoguchi)
30+
2931
PIG-5385: Skip calling extra gc() before spilling large bag when unnecessary (knoguchi)
3032

3133
PIG-5389: Passing null to REPLACE udf preventing JIT optimization (knoguchi)

build.xml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,7 @@
268268
<property name="ivy.lib.dir.spark" location="${ivy.lib.dir}/spark" />
269269
<property name="build.ivy.report.dir" location="${build.ivy.dir}/report" />
270270
<property name="build.ivy.maven.dir" location="${build.ivy.dir}/maven" />
271+
<property name="build.ivy.owasp.dir" location="${build.ivy.dir}/owasp" />
271272
<property name="pom.xml" location="${build.ivy.maven.dir}/pom.xml"/>
272273
<property name="build.ivy.maven.pom" location="${build.ivy.maven.dir}/pig-${version}.pom" />
273274
<property name="build.ivy.maven.jar" location="${build.ivy.maven.dir}/pig-${version}-core.jar" />
@@ -1461,6 +1462,21 @@
14611462
<!-- Perform audit activities for the release -->
14621463
<!-- ================================================================== -->
14631464

1465+
<target name="owasp" depends="ivy-owasp,ivy-compile" description="OWASP dependency check">
1466+
<typedef format="properties" resource="dependency-check-taskdefs.properties" uri="antlib:org.owasp.dependencycheck.anttasks" classpathref="owasp-classpath"/>
1467+
<owasp:dependency-check xmlns:owasp="antlib:org.owasp.dependencycheck.anttasks"
1468+
projectname="Pig"
1469+
reportoutputdirectory="${build.dir}/owasp"
1470+
reportformat="ALL"
1471+
failBuildOnCVSS="0">
1472+
1473+
<fileset dir="${ivy.lib.dir}">
1474+
<include name="**/*.jar"/>
1475+
</fileset>
1476+
1477+
</owasp:dependency-check>
1478+
</target>
1479+
14641480
<target name="releaseaudit" depends="ivy-releaseaudit" description="generate a release audit report">
14651481
<get src="${mvnrepo}/org/apache/rat/apache-rat/${apacherat.version}/apache-rat-${apacherat.version}.jar"
14661482
dest="${basedir}/build/apache-rat-${apacherat.version}.jar"
@@ -1759,6 +1775,12 @@
17591775
<ivy:cachepath pathid="jdiff.classpath" conf="jdiff"/>
17601776
</target>
17611777

1778+
<target name="ivy-owasp" depends="ivy-resolve" description="Retrieve Ivy-managed artifacts for owasp configuration">
1779+
<ivy:retrieve settingsRef="${ant.project.name}.ivy.settings" log="${loglevel}"
1780+
pattern="${build.ivy.owasp.dir}/${ivy.artifact.retrieve.pattern}" conf="owasp"/>
1781+
<ivy:cachepath pathid="owasp-classpath" conf="owasp"/>
1782+
</target>
1783+
17621784
<target name="ivy-clean-cache" depends="ivy-init-antlib"
17631785
description="Clean the Ivy cache">
17641786
<ivy:cleancache />

ivy.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
<conf name="hbase2" visibility="private"/>
4444
<conf name="spark1" visibility="private" />
4545
<conf name="spark2" visibility="private" />
46+
<conf name="owasp" visibility="private" description="Artifacts required for owasp target"/>
4647
</configurations>
4748
<publications>
4849
<artifact name="pig" conf="master"/>
@@ -614,6 +615,9 @@
614615
conf="hadoop2->master"/>
615616
<dependency org="org.apache.curator" name="curator-client" rev="${curator.version}"
616617
conf="hadoop2->master"/>
618+
<!-- For dependency check -->
619+
<dependency org="org.owasp" name="dependency-check-ant"
620+
rev="${dependency-check-ant.version}" conf="owasp->default"/>
617621
</dependencies>
618622
</ivy-module>
619623

ivy/libraries.properties

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,4 +97,5 @@ htrace4.version=4.0.1-incubating
9797
commons-lang3.version=3.6
9898
scala-xml.version=1.0.5
9999
glassfish.el.version=3.0.1-b08
100-
roaring-bitmap-shaded.version=0.7.14
100+
roaring-bitmap-shaded.version=0.7.14
101+
dependency-check-ant.version=5.2.4

0 commit comments

Comments
 (0)