[sslext] Initial import (#826647)

gil gil at fedoraproject.org
Wed Jul 11 10:08:00 UTC 2012


commit b2d68c0771bae8f1db19fd9faaba585575f453d9
Author: gil <puntogil at libero.it>
Date:   Wed Jul 11 12:07:36 2012 +0200

    Initial import (#826647)

 .gitignore                          |    1 +
 sources                             |    1 +
 sslext-1.2-0.pom                    |   25 ++++++++
 sslext-1.2-SecureRequestUtils.patch |   29 +++++++++
 sslext-1.2-build.patch              |   39 ++++++++++++
 sslext-1.2-javadocs.patch           |   46 +++++++++++++++
 sslext-1.2-pom.patch                |   26 ++++++++
 sslext.spec                         |  109 +++++++++++++++++++++++++++++++++++
 8 files changed, 276 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..1e024cd 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/sslext-1.2-realclean-src-cvs.tar.gz
diff --git a/sources b/sources
index e69de29..6773e3f 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+2b5457d0e0a58446ba54cb1490107acc  sslext-1.2-realclean-src-cvs.tar.gz
diff --git a/sslext-1.2-0.pom b/sslext-1.2-0.pom
new file mode 100644
index 0000000..08d4d04
--- /dev/null
+++ b/sslext-1.2-0.pom
@@ -0,0 +1,25 @@
+<project>
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>sslext</groupId>
+  <artifactId>sslext</artifactId>
+  <name>sslext</name>
+  <version>1.2-0</version>
+  <licenses>
+    <license>
+      <name>Apache Software License, Version 1.1</name>
+      <url>http://www.apache.org/licenses/LICENSE-1.1</url>
+      <comments></comments>
+    </license>
+  </licenses>
+  <organization>
+    <name>Steve Ditlinger</name>
+    <url>http://sslext.sourceforge.net/</url>
+  </organization>
+  <dependencies>
+    <dependency>
+      <groupId>struts</groupId>
+      <artifactId>struts</artifactId>
+      <version>1.2.7</version>
+    </dependency>
+  </dependencies>
+</project>
\ No newline at end of file
diff --git a/sslext-1.2-SecureRequestUtils.patch b/sslext-1.2-SecureRequestUtils.patch
new file mode 100644
index 0000000..f48af2d
--- /dev/null
+++ b/sslext-1.2-SecureRequestUtils.patch
@@ -0,0 +1,29 @@
+--- src/org/apache/struts/util/SecureRequestUtils.java	2004-09-27 02:02:23.000000000 +0200
++++ src/org/apache/struts/util/SecureRequestUtils.java-gil	2011-09-10 11:25:12.260719716 +0200
+@@ -358,10 +358,10 @@
+          return false;
+       }
+ 
+-      Enumeration enum = aRequest.getAttributeNames();
++      Enumeration mune = aRequest.getAttributeNames();
+       Map map = new HashMap();
+-      while (enum.hasMoreElements()) {
+-         String name = (String) enum.nextElement();
++      while (mune.hasMoreElements()) {
++         String name = (String) mune.nextElement();
+          map.put(name, aRequest.getAttribute(name));
+       }
+       aRequest.getSession().setAttribute(STOWED_REQUEST_ATTRIBS, map);
+@@ -534,9 +534,9 @@
+     */
+    private static Map getParameterMap(HttpServletRequest request) {
+       Map map = new HashMap();
+-      Enumeration enum = request.getParameterNames();
+-      while (enum.hasMoreElements()) {
+-         String name = (String) enum.nextElement();
++      Enumeration mune = request.getParameterNames();
++      while (mune.hasMoreElements()) {
++         String name = (String) mune.nextElement();
+          String[] values = request.getParameterValues(name);
+          map.put(name, values);
+       }
diff --git a/sslext-1.2-build.patch b/sslext-1.2-build.patch
new file mode 100644
index 0000000..8227780
--- /dev/null
+++ b/sslext-1.2-build.patch
@@ -0,0 +1,39 @@
+--- build.xml	2004-09-18 21:56:33.000000000 +0200
++++ build.xml-gil	2012-06-06 11:11:15.937687091 +0200
+@@ -5,14 +5,24 @@
+     <property name="classes" value="${web-inf}/classes"/>
+     <property name="lib" value="${web-inf}/lib"/>
+     <!-- <property name="build.compiler" value="jikes"/> -->
+-    <property name="j2ee.lib" value="../lib/j2ee12.jar"/>
++    <property name="j2ee.lib" value="/usr/share/java/tomcat-servlet-3.0-api.jar"/>
+     <property file="buildsslext.properties"/>
+ 
+     <path id="class.path">
+         <pathelement path="${src}"/>
+         <pathelement path="${j2ee.lib}"/>
+-        <fileset dir="${lib}">
+-            <include name="**/*.jar"/>
++        <fileset dir="/usr/share/java/">
++            <include name="commons-beanutils.jar"/>
++            <include name="commons-collections.jar"/>
++            <include name="commons-digester.jar"/>
++            <include name="commons-fileupload.jar"/>
++            <include name="commons-logging.jar"/>
++            <include name="commons-validator.jar"/>
++            <include name="oro.jar"/>
++            <include name="struts/core.jar"/>
++            <include name="struts/taglib.jar"/>
++            <include name="struts/tiles.jar"/>
++            <include name="tomcat-jsp-2.2-api.jar"/>
+         </fileset>
+     </path>
+ 
+@@ -26,6 +36,8 @@
+             destdir="${classes}"
+             classpathref="class.path"
+             debug="on"
++            source="1.5"
++            target="1.5"
+         />
+     </target>
+ 
diff --git a/sslext-1.2-javadocs.patch b/sslext-1.2-javadocs.patch
new file mode 100644
index 0000000..60bc5d0
--- /dev/null
+++ b/sslext-1.2-javadocs.patch
@@ -0,0 +1,46 @@
+--- build.xml	2012-07-09 17:55:25.669707599 +0200
++++ build.xml-gil	2012-07-09 17:55:37.292140796 +0200
+@@ -26,6 +26,14 @@
+         </fileset>
+     </path>
+ 
++   <path id="javadoc.classpath">
++    <path refid="class.path"/>
++    <pathelement location="${classes}/**"/>
++    <fileset dir="${lib}">
++            <include name="sslext.jar"/>
++    </fileset>
++   </path>
++
+     <target name="init">
+         <tstamp/>
+     </target>
+@@ -144,6 +152,28 @@
+      	/>
+     </target>
+ 
++    <target name="javadoc" description="generates javadocs">
++        <mkdir dir="docs"/>
++        <tstamp>
++            <format property="year" pattern="yyyy" />
++        </tstamp>
++        <!-- Locale must be before any doclet parameters -->
++        <javadoc
++            packagenames="*"
++            Locale="en_US"
++            sourcepath="${src}"
++            destdir="docs"
++            author="true"
++            version="true"
++            private="false"
++            use="true"
++            windowtitle="Struts SSL Switching Extension">
++            <doctitle><![CDATA[<h2>Struts SSL Switching Extension</h2>]]></doctitle>
++            <bottom><![CDATA[<i>Copyright 1999, ${year} The Apache Software Foundation,  All Rights Reserved</i>]]></bottom>
++            <classpath refid="javadoc.classpath"/>
++        </javadoc>
++    </target>
++    
+      <target name="make-bin-zips" depends="make-jar, make-bin-tar, make-bin-zip">
+     </target>
+    
diff --git a/sslext-1.2-pom.patch b/sslext-1.2-pom.patch
new file mode 100644
index 0000000..6f90e4a
--- /dev/null
+++ b/sslext-1.2-pom.patch
@@ -0,0 +1,26 @@
+--- pom.xml	2005-11-08 22:53:43.000000000 +0100
++++ pom.xml-gil	2012-05-27 05:19:18.277207739 +0200
+@@ -17,9 +17,19 @@
+   </organization>
+   <dependencies>
+     <dependency>
+-      <groupId>struts</groupId>
+-      <artifactId>struts</artifactId>
+-      <version>1.2.7</version>
++      <groupId>org.apache.struts</groupId>
++      <artifactId>struts-core</artifactId>
++      <version>1.3.10</version>
++    </dependency>
++    <dependency>
++      <groupId>org.apache.struts</groupId>
++      <artifactId>struts-taglib</artifactId>
++      <version>1.3.10</version>
++    </dependency>
++    <dependency>
++      <groupId>org.apache.struts</groupId>
++      <artifactId>struts-tiles</artifactId>
++      <version>1.3.10</version>
+     </dependency>
+   </dependencies>
+ </project>
+\ Manca newline alla fine del file
diff --git a/sslext.spec b/sslext.spec
new file mode 100644
index 0000000..51230d5
--- /dev/null
+++ b/sslext.spec
@@ -0,0 +1,109 @@
+Name:          sslext
+Version:       1.2
+Release:       2%{?dist}
+Summary:       Struts SSL Switching Extension
+Group:         Development/Libraries
+License:       ASL 1.1
+Url:           http://sslext.sourceforge.net/
+#cvs -d:pserver:anonymous at sslext.cvs.sourceforge.net:/cvsroot/sslext login
+#cvs -z3 -d:pserver:anonymous at sslext.cvs.sourceforge.net:/cvsroot/sslext export -r Release1_2_1 sslext120
+#rm -rf sslext120/web/WEB-INF/lib/*.jar
+#rm -rf sslext120/sslext-struts1.2-*.*
+#rm -rf $(find sslext120 -name "CVS")
+#rm -rf $(find sslext120 -name "*.class")
+#rm -rf $(find sslext120 -name "*.bak")
+# non free
+# rm -rf sslext120/web/WEB-INF/web-app_2_3.dtd
+#mv sslext120 sslext-1.2
+#tar czf sslext-1.2-realclean-src-cvs.tar.gz sslext-1.2
+Source0:       %{name}-%{version}-realclean-src-cvs.tar.gz
+Source1:       http://repo1.maven.org/maven2/%{name}/%{name}/%{version}-0/%{name}-%{version}-0.pom
+Patch0:        %{name}-%{version}-build.patch
+# fix build java5+
+Patch1:        %{name}-%{version}-SecureRequestUtils.patch
+# update struts reference
+Patch2:        %{name}-%{version}-pom.patch
+# build apis documentation
+Patch3:        %{name}-%{version}-javadocs.patch
+
+BuildRequires: java-devel
+BuildRequires: jpackage-utils
+
+BuildRequires: ant
+BuildRequires: apache-commons-beanutils
+BuildRequires: apache-commons-collections
+BuildRequires: apache-commons-digester
+BuildRequires: apache-commons-fileupload
+BuildRequires: apache-commons-logging
+BuildRequires: apache-commons-validator
+BuildRequires: jakarta-oro
+BuildRequires: struts
+BuildRequires: tomcat-jsp-2.2-api
+BuildRequires: tomcat-servlet-3.0-api
+
+Requires:      apache-commons-digester
+Requires:      apache-commons-logging
+Requires:      struts
+Requires:      tomcat-servlet-3.0-api
+Requires:      tomcat-jsp-2.2-api
+
+Requires:      java
+Requires:      jpackage-utils
+BuildArch:     noarch
+
+%description
+Extension to the Struts framework that allows developers to configure web
+applications to automatically switch between the HTTP and HTTPS protocols.
+Configuration is performed within the Struts config XML file.
+
+%package javadoc
+Group:         Documentation
+Summary:       Javadoc for %{name}
+Requires:      jpackage-utils
+
+%description javadoc
+This package contains javadoc for %{name}.
+
+%prep
+%setup -q
+mkdir -p web/WEB-INF/classes
+%patch0 -p0
+%patch1 -p0
+cp -p %{SOURCE1} pom.xml
+%patch2 -p0
+%patch3 -p0
+
+%build
+
+export CLASSPATH=$(build-classpath tomcat-jsp-2.2-api tomcat-servlet-3.0-api)
+%ant compile make-jar javadoc
+
+%install
+
+mkdir -p %{buildroot}%{_javadir}
+install -m 644 web/WEB-INF/lib/%{name}.jar %{buildroot}%{_javadir}/
+
+mkdir -p %{buildroot}%{_mavenpomdir}
+install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
+%add_maven_depmap JPP-%{name}.pom %{name}.jar
+
+mkdir -p %{buildroot}%{_javadocdir}/%{name}
+cp -pr docs/* %{buildroot}%{_javadocdir}/%{name}
+
+%files
+%{_javadir}/%{name}.jar
+%{_mavenpomdir}/JPP-%{name}.pom
+%{_mavendepmapfragdir}/%{name}
+
+%files javadoc
+%{_javadocdir}/%{name}
+
+%changelog
+* Mon Jul 09 2012 gil cattaneo <puntogil at libero.it> 1.2-2
+- removed non-free file
+- fixed spelling errors in description
+- added missing dependencies
+- added javadoc sub package
+
+* Sun May 27 2012 gil cattaneo <puntogil at libero.it> 1.2-1
+- initial rpm
\ No newline at end of file


More information about the scm-commits mailing list