summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlin Năstac <mrness@gentoo.org>2005-05-26 05:16:52 +0000
committerAlin Năstac <mrness@gentoo.org>2005-05-26 05:16:52 +0000
commitc83a8f81f5d3f0a39ccc256c27c33758bb87c981 (patch)
tree1dbdca7f6bcad06c8beeabe2d5dfaf0624676626 /net-proxy
parentNew revision with FreeBSD's ports patches (for compatibility with Gentoo/Free... (diff)
downloadgentoo-2-c83a8f81f5d3f0a39ccc256c27c33758bb87c981.tar.gz
gentoo-2-c83a8f81f5d3f0a39ccc256c27c33758bb87c981.tar.bz2
gentoo-2-c83a8f81f5d3f0a39ccc256c27c33758bb87c981.zip
version bump; new version is compiled from source and it could be launched by normal users (#93893)
(Portage version: 2.0.51.19)
Diffstat (limited to 'net-proxy')
-rw-r--r--net-proxy/paros/ChangeLog10
-rw-r--r--net-proxy/paros/Manifest15
-rw-r--r--net-proxy/paros/files/digest-paros-3.2.11
-rw-r--r--net-proxy/paros/files/paros-3.2.1-unixhome.patch200
-rw-r--r--net-proxy/paros/paros-3.2.1.ebuild44
5 files changed, 258 insertions, 12 deletions
diff --git a/net-proxy/paros/ChangeLog b/net-proxy/paros/ChangeLog
index bb85354fe84f..96dc4284459f 100644
--- a/net-proxy/paros/ChangeLog
+++ b/net-proxy/paros/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for net-proxy/paros
# Copyright 1999-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-proxy/paros/ChangeLog,v 1.3 2005/05/05 05:13:56 mrness Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-proxy/paros/ChangeLog,v 1.4 2005/05/26 05:16:52 mrness Exp $
+
+*paros-3.2.1 (26 May 2005)
+
+ 26 May 2005; Alin Nastac <mrness@gentoo.org>
+ +files/paros-3.2.1-unixhome.patch, +paros-3.2.1.ebuild:
+ Version bump. The new version is compiled from source and it could be
+ launched by regular users, thanks to a patch submitted by Stefan Schlott
+ <stefan.schlott@informatik.uni-ulm.de> (#93893).
05 May 2005; Alin Nastac <mrness@gentoo.org> paros-3.2.0.ebuild:
Fix dependencies (#91407) and mark it stable on x86.
diff --git a/net-proxy/paros/Manifest b/net-proxy/paros/Manifest
index 05a3c38f15d1..929dc6ef5f0f 100644
--- a/net-proxy/paros/Manifest
+++ b/net-proxy/paros/Manifest
@@ -1,14 +1,7 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
-
+MD5 52a0c608708618f84d21bf9f80520906 paros-3.2.1.ebuild 957
MD5 de85e8e039a568872522fb31405a807e paros-3.2.0.ebuild 726
-MD5 11822789ab964e2420fb61a4dab1de4c ChangeLog 572
+MD5 edf7222c925896d7a7c2bec9404ca515 ChangeLog 904
MD5 4b03e120ede9dfedec0594e35156b38c metadata.xml 256
+MD5 d94a73453cb13809517ded8065abbaf7 files/paros-3.2.1-unixhome.patch 8462
MD5 63433745c47ead240f2be10aa5d8954d files/digest-paros-3.2.0 66
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.1 (GNU/Linux)
-
-iD8DBQFCeaujjiC39V7gKu0RAvRWAKCLCGZHbmJQNftmkBauHAQWIkvfSwCgm6uz
-rgE8J+QNLEw9Eh1dejVbg2Y=
-=Q4xW
------END PGP SIGNATURE-----
+MD5 a721e44c8406402cbb63892f10156ab3 files/digest-paros-3.2.1 65
diff --git a/net-proxy/paros/files/digest-paros-3.2.1 b/net-proxy/paros/files/digest-paros-3.2.1
new file mode 100644
index 000000000000..18b2817c30ef
--- /dev/null
+++ b/net-proxy/paros/files/digest-paros-3.2.1
@@ -0,0 +1 @@
+MD5 f716bdd16cdfdf9a95fc9ec014401bad paros-3.2.1-src.zip 3151758
diff --git a/net-proxy/paros/files/paros-3.2.1-unixhome.patch b/net-proxy/paros/files/paros-3.2.1-unixhome.patch
new file mode 100644
index 000000000000..d1170795d125
--- /dev/null
+++ b/net-proxy/paros/files/paros-3.2.1-unixhome.patch
@@ -0,0 +1,200 @@
+diff -uNr paros.orig/src/org/parosproxy/paros/Constant.java paros/src/org/parosproxy/paros/Constant.java
+--- paros.orig/src/org/parosproxy/paros/Constant.java 2005-05-06 23:30:32.000000000 +0200
++++ paros/src/org/parosproxy/paros/Constant.java 2005-05-25 09:17:49.000000000 +0200
+@@ -21,6 +21,11 @@
+ */
+ package org.parosproxy.paros;
+
++import org.apache.commons.logging.Log;
++import org.apache.commons.logging.LogFactory;
++import java.io.*;
++import java.nio.channels.*;
++
+ /**
+ *
+ * To change the template for this generated type comment go to
+@@ -31,13 +36,18 @@
+ public static final String PROGRAM_VERSION = "3.2.1";
+ public static final String PROGRAM_TITLE = PROGRAM_NAME + " " + PROGRAM_VERSION;
+
+- public static final String FILE_OPTIONS = "xml/options.xml";
++ public static final String FILE_OPTIONS_DEFAULT = "xml/options.xml";
++ public String FILE_OPTIONS = "options.xml";
+ public static final String FOLDER_PLUGIN = "plugin";
+ public static final String FOLDER_FILTER = "filter";
+- public static final String FOLDER_SESSION = "session";
+- public static final String DBNAME_TEMPLATE = "db/parosdb";
+- public static final String DBNAME_UNTITLED = FOLDER_SESSION + "/untitled";
++ public static final String FOLDER_SESSION_DEFAULT = "session";
++ public String FOLDER_SESSION = "session";
++ public static final String DBNAME_TEMPLATE = "db/parosdb";
++ public String DBNAME_UNTITLED = FOLDER_SESSION + "/untitled";
++ public String ACCEPTED_LICENSE = "AcceptedLicense";
+
++ static private Constant instance = null;
++
+ public static final int MAX_HOST_CONNECTION = 5;
+ public static final String USER_AGENT = PROGRAM_NAME + "/" + PROGRAM_VERSION;
+
+@@ -60,5 +70,57 @@
+ return staticSP;
+ }
+
+-
++ public static void copyFile(File in, File out) throws Exception {
++ if (!in.exists())
++ throw new IOException("Source file does not exist");
++/* FileChannel sourceChannel = new FileInputStream(in).getChannel();
++ FileChannel destinationChannel = new FileOutputStream(out).getChannel();
++ sourceChannel.transferTo(0, in.length(), destinationChannel);
++ sourceChannel.close();
++ destinationChannel.close();*/
++ FileReader inf = new FileReader(in);
++ FileWriter outf = new FileWriter(out);
++ int c;
++ while ((c=inf.read()) != -1)
++ outf.write(c);
++ inf.close();
++ outf.close();
++ }
++
++ public Constant() {
++ String userhome = System.getProperty("user.home") + System.getProperty("file.separator")+".paros";
++ File f = new File(userhome);
++ userhome += System.getProperty("file.separator");
++ FILE_OPTIONS=userhome+FILE_OPTIONS;
++ FOLDER_SESSION=userhome+FOLDER_SESSION;
++ DBNAME_UNTITLED=userhome+DBNAME_UNTITLED;
++ ACCEPTED_LICENSE=userhome+ACCEPTED_LICENSE;
++ try {
++ Log log = LogFactory.getLog(Constant.class);
++ if (!f.isDirectory()) {
++ log.info("Creating directory "+userhome);
++ f.mkdir();
++ }
++ f=new File(FILE_OPTIONS);
++ if (!f.isFile()) {
++ log.info("Copying defaults from "+FILE_OPTIONS_DEFAULT+" to "+FILE_OPTIONS);
++ copyFile(new File(FILE_OPTIONS_DEFAULT),f);
++ }
++ f=new File(FOLDER_SESSION);
++ if (!f.isDirectory()) {
++ log.info("Creating directory "+FOLDER_SESSION);
++ f.mkdir();
++ }
++ } catch (Exception e) {
++ System.err.println("Unable to initialize home directory! " + e.getMessage());
++ e.printStackTrace(System.err);
++ System.exit(1);
++ }
++ }
++
++ public static Constant getInstance() {
++ if (instance==null)
++ instance=new Constant();
++ return instance;
++ }
+ }
+diff -uNr paros.orig/src/org/parosproxy/paros/Paros.java paros/src/org/parosproxy/paros/Paros.java
+--- paros.orig/src/org/parosproxy/paros/Paros.java 2005-05-06 00:05:48.000000000 +0200
++++ paros/src/org/parosproxy/paros/Paros.java 2005-05-25 08:32:21.000000000 +0200
+@@ -169,7 +169,7 @@
+ }
+
+ private void showLicense() {
+- if (!(new File("license/AcceptedLicense")).exists()){
++ if (!(new File(Constant.getInstance().ACCEPTED_LICENSE)).exists()){
+
+ LicenseFrame license = new LicenseFrame();
+ license.setVisible(true);
+@@ -181,7 +181,7 @@
+ }
+
+ try{
+- FileWriter fo = new FileWriter("license/AcceptedLicense");
++ FileWriter fo = new FileWriter(Constant.getInstance().ACCEPTED_LICENSE);
+ fo.close();
+ }catch (IOException ie){
+ JOptionPane.showMessageDialog(new JFrame(), "Unknown Error. Please report to the author.");
+diff -uNr paros.orig/src/org/parosproxy/paros/control/Control.java paros/src/org/parosproxy/paros/control/Control.java
+--- paros.orig/src/org/parosproxy/paros/control/Control.java 2005-04-08 00:17:28.000000000 +0200
++++ paros/src/org/parosproxy/paros/control/Control.java 2005-05-25 08:31:01.000000000 +0200
+@@ -62,7 +62,7 @@
+ loadExtension();
+
+ try {
+- model.getOptionsParam().readAndParseFile(Constant.FILE_OPTIONS);
++ model.getOptionsParam().readAndParseFile(Constant.getInstance().FILE_OPTIONS);
+ } catch (Exception e) {}
+
+ getProxy();
+diff -uNr paros.orig/src/org/parosproxy/paros/control/MenuToolsControl.java paros/src/org/parosproxy/paros/control/MenuToolsControl.java
+--- paros.orig/src/org/parosproxy/paros/control/MenuToolsControl.java 2004-11-08 20:30:46.000000000 +0100
++++ paros/src/org/parosproxy/paros/control/MenuToolsControl.java 2005-05-25 08:30:48.000000000 +0200
+@@ -59,7 +59,7 @@
+ dialog.initParam(model.getOptionsParam());
+ int result = dialog.showDialog(false);
+ if (result == JOptionPane.OK_OPTION) {
+- model.getOptionsParam().saveFile(Constant.FILE_OPTIONS);
++ model.getOptionsParam().saveFile(Constant.getInstance().FILE_OPTIONS);
+ control.getProxy().stopServer();
+ control.getProxy().startServer();
+ }
+diff -uNr paros.orig/src/org/parosproxy/paros/model/Model.java paros/src/org/parosproxy/paros/model/Model.java
+--- paros.orig/src/org/parosproxy/paros/model/Model.java 2005-01-17 22:36:38.000000000 +0100
++++ paros/src/org/parosproxy/paros/model/Model.java 2005-05-25 08:30:31.000000000 +0200
+@@ -40,7 +40,7 @@
+ private static Model model = null;
+
+ private static final String DBNAME_TEMPLATE = Constant.DBNAME_TEMPLATE;
+- private static final String DBNAME_UNTITLED = Constant.DBNAME_UNTITLED;
++ private String DBNAME_UNTITLED = Constant.getInstance().DBNAME_UNTITLED;
+ private static int DBNAME_COPY = 1;
+
+ private Session session = null;
+@@ -93,7 +93,7 @@
+
+ createAndOpenUntitledDb();
+ HistoryReference.setTableHistory(getDb().getTableHistory());
+- getOptionsParam().readAndParseFile(Constant.FILE_OPTIONS);
++ getOptionsParam().readAndParseFile(Constant.getInstance().FILE_OPTIONS);
+ }
+
+
+diff -uNr paros.orig/src/org/parosproxy/paros/model/Session.java paros/src/org/parosproxy/paros/model/Session.java
+--- paros.orig/src/org/parosproxy/paros/model/Session.java 2005-01-20 22:56:44.000000000 +0100
++++ paros/src/org/parosproxy/paros/model/Session.java 2005-05-25 08:28:52.000000000 +0200
+@@ -313,7 +313,7 @@
+ public String getSessionFolder() {
+ String result = "";
+ if (fileName.equals("")) {
+- result = Constant.FOLDER_SESSION;
++ result = Constant.getInstance().FOLDER_SESSION;
+ } else {
+ File file = new File(fileName);
+ result = file.getParent();
+diff -uNr paros.orig/src/xml/log4j.properties paros/src/xml/log4j.properties
+--- paros.orig/src/xml/log4j.properties 2004-11-09 00:20:36.000000000 +0100
++++ paros/src/xml/log4j.properties 2005-05-25 08:26:28.000000000 +0200
+@@ -1,8 +1,12 @@
+-log4j.rootLogger=info, R
++log4j.rootLogger=info, stdout
+
++log4j.appender.stdout=org.apache.log4j.ConsoleAppender
++log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
++#log4j.appender.stdout.layout.ConversionPattern=%d [%-5t] %-5p %c{1} - %m%n
++log4j.appender.stdout.layout.ConversionPattern=%d %-5p %c{1} - %m%n
+
+ log4j.appender.R=org.apache.log4j.RollingFileAppender
+-log4j.appender.R.File=log/paros.message.txt
++log4j.appender.R.File=/tmp/paros.message.txt
+
+ log4j.appender.R.MaxFileSize=2048KB
+ # Keep one backup file
+@@ -13,4 +17,4 @@
+ log4j.appender.R.layout.ConversionPattern=%d %-5p %c{1} - %m%n
+
+ log4j.logger.org.parosproxy.paros=INFO
+-log4j.logger.org.apache.commons.httpclient=ERROR
+\ No newline at end of file
++log4j.logger.org.apache.commons.httpclient=ERROR
diff --git a/net-proxy/paros/paros-3.2.1.ebuild b/net-proxy/paros/paros-3.2.1.ebuild
new file mode 100644
index 000000000000..62b108dc1ccc
--- /dev/null
+++ b/net-proxy/paros/paros-3.2.1.ebuild
@@ -0,0 +1,44 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-proxy/paros/paros-3.2.1.ebuild,v 1.1 2005/05/26 05:16:52 mrness Exp $
+
+inherit eutils
+
+DESCRIPTION="HTTP/HTTPS proxy for evaluate security of web applications"
+HOMEPAGE="http://www.parosproxy.org/"
+SRC_URI="mirror://sourceforge/${PN}/${P}-src.zip"
+
+LICENSE="Clarified-Artistic"
+SLOT="0"
+KEYWORDS="~x86"
+IUSE=""
+
+DEPEND="app-arch/unzip
+ >=virtual/jdk-1.4.2
+ dev-java/ant"
+RDEPEND=">=virtual/jre-1.4.2"
+
+S="${WORKDIR}/${PN}"
+
+src_unpack() {
+ unpack ${A}
+
+ cd ${S}
+ epatch ${FILESDIR}/${PF}-unixhome.patch
+}
+
+src_compile() {
+ cd ${S}/build
+ ant dist || die "ant failed"
+}
+
+src_install() {
+ sed -i -e '1i#!/bin/sh' -e "1icd /usr/share/${PN}" build/${PN}/startserver.sh
+ newbin build/${PN}/startserver.sh ${PN}
+ rm build/${PN}/startserver.*
+
+ insinto /usr/share
+ doins -r build/${PN}
+
+ dodoc src/doc/{*.txt,*.rtf}
+}