summaryrefslogtreecommitdiff
path: root/security/pgp6
diff options
context:
space:
mode:
authorWill Andrews <will@FreeBSD.org>2000-05-29 06:17:54 +0000
committerWill Andrews <will@FreeBSD.org>2000-05-29 06:17:54 +0000
commit46bf503a0a2a3bc7dd3d70ee2f5c9f795333fbb2 (patch)
tree7e18f02d8c0b9e2769c06e44139472ea14b22466 /security/pgp6
parentAdd xtrojka, a skill game similar to T*tris. (diff)
Update to PGP (International version) 6.5.1i. This is actually a new
port, repo-copied from security/pgp5 by asami. I added a bunch of the intl mirrors to make this port super-available. PR: 16377 Submitted by: Mike Sherwood <mike@fate.com>
Notes
Notes: svn path=/head/; revision=28909
Diffstat (limited to 'security/pgp6')
-rw-r--r--security/pgp6/Makefile39
-rw-r--r--security/pgp6/distinfo2
-rw-r--r--security/pgp6/files/build.Makefile16
-rw-r--r--security/pgp6/files/patch-ag25
-rw-r--r--security/pgp6/files/patch-ah19
-rw-r--r--security/pgp6/files/patch-ai25
-rw-r--r--security/pgp6/files/patch-aj15
-rw-r--r--security/pgp6/files/patch-ak70
-rw-r--r--security/pgp6/files/patch-al31
-rw-r--r--security/pgp6/files/patch-am36
-rw-r--r--security/pgp6/files/patch-an220
-rw-r--r--security/pgp6/files/patch-ao15
-rw-r--r--security/pgp6/files/patch-ap19
-rw-r--r--security/pgp6/files/patch-aq15
-rw-r--r--security/pgp6/pkg-descr26
-rw-r--r--security/pgp6/pkg-plist15
16 files changed, 540 insertions, 48 deletions
diff --git a/security/pgp6/Makefile b/security/pgp6/Makefile
index c4edc91c275d..cf1c5cb968a5 100644
--- a/security/pgp6/Makefile
+++ b/security/pgp6/Makefile
@@ -1,27 +1,34 @@
-# New ports collection makefile for: pgp5
-# Date created: 10 Feb 1998
-# Whom: markm
+# New ports collection makefile for: pgp6
+# Date created: 25 Jan 2000
+# Whom: mike@fate.com
#
# $FreeBSD$
#
PORTNAME= pgp
-PORTVERSION= 5.0i
+PORTVERSION= 6.5.1i
CATEGORIES= security
-MASTER_SITES= ftp://ftp.ifi.uio.no/pub/pgp/5.0/unix/ \
- ftp://ftp.doc.ic.ac.uk/pub/Mirrors/ftp.ifi.uio.no/pub/pgp/5.0/unix/
-DISTNAME= pgp50i
-EXTRACT_SUFX= -unix-src.tar.gz
+MASTER_SITES= ftp://ftp.no.pgpi.org/pub/pgp/6.5/6.5.1i/unix/ \
+ ftp://ftp.fi.pgpi.org/pub/pgp/6.5/6.5.1i/unix/ \
+ ftp://ftp.se.pgpi.org/pub/pgp/6.5/6.5.1i/unix/ \
+ ftp://ftp.de.pgpi.org/pub/pgp/6.5/6.5.1i/unix/ \
+ ftp://ftp.dk.pgpi.org/pub/pgp/6.5/6.5.1i/unix/ \
+ ftp://ftp.nl.pgpi.org/pub/pgp/6.5/6.5.1i/unix/ \
+ ftp://ftp.ch.pgpi.org/pub/pgp/6.5/6.5.1i/unix/ \
+ ftp://ftp.ru.pgpi.org/pub/pgp/6.5/6.5.1i/unix/
+EXTRACT_SUFX= -beta2.tar.gz
-MAINTAINER= markm@FreeBSD.org
+MAINTAINER= mike@fate.com
-Y2K= http://www.pgpi.com/faq/pgpi.shtml#Year2000
+WRKSRC= ${WRKDIR}/${DISTNAME}
+USE_GMAKE= YES
-WRKSRC= ${WRKDIR}/${DISTNAME}/src
-GNU_CONFIGURE= yes
-RESTRICTED= "Crypto"
-MAN1= pgp5.1 pgpe.1 pgpk.1 pgps.1 pgpv.1
-MAN5= pgp.cfg.5
-MAN7= pgp-integration.7 pgp-intro.7
+RESTRICTED= "Crypto"
+
+do-install:
+ cd ${WRKSRC}/clients/pgp/cmdline ; ${GMAKE} install
+
+post-extract:
+ ${CP} ${FILESDIR}/build.Makefile ${WRKDIR}/${PKGNAME}/Makefile
.include <bsd.port.mk>
diff --git a/security/pgp6/distinfo b/security/pgp6/distinfo
index 473539d67ca3..1eccdf7cfd96 100644
--- a/security/pgp6/distinfo
+++ b/security/pgp6/distinfo
@@ -1 +1 @@
-MD5 (pgp50i-unix-src.tar.gz) = 7a01203f0053aa78a781367461d52187
+MD5 (pgp-6.5.1i-beta2.tar.gz) = ccfbd70fd0e08a8c13e9c15ea1db085a
diff --git a/security/pgp6/files/build.Makefile b/security/pgp6/files/build.Makefile
new file mode 100644
index 000000000000..3d3c64a1124e
--- /dev/null
+++ b/security/pgp6/files/build.Makefile
@@ -0,0 +1,16 @@
+#
+# build.sh expressed as a makefile
+# mike@fate.com
+#
+
+all:
+ cd libs/pfl ; ./configure
+ cd libs/pfl ; gmake
+ cd libs/pgpcdk ; ./configure
+ cd libs/pgpcdk ; gmake headers
+ cd libs/pgpcdk ; gmake
+ cd clients/pgp/shared ; ./configure
+ cd clients/pgp/shared ; gmake
+ cd clients/pgp/cmdline ; ./configure
+ cd clients/pgp/cmdline ; gmake
+
diff --git a/security/pgp6/files/patch-ag b/security/pgp6/files/patch-ag
new file mode 100644
index 000000000000..8b0d8cdf1d95
--- /dev/null
+++ b/security/pgp6/files/patch-ag
@@ -0,0 +1,25 @@
+*** libs/pfl/common/pgpRMWOLock.c 2000/01/25 23:30:04 1.1.1.1
+--- libs/pfl/common/pgpRMWOLock.c 2000/01/25 23:32:31 1.1.1.2
+***************
+*** 8,15 ****
+ ____________________________________________________________________________*/
+
+ #include "pgpBase.h"
+
+ #include "pgpRMWOLock.h"
+
+ #if PGP_UNIX_SOLARIS
+ /*
+--- 8,19 ----
+ ____________________________________________________________________________*/
+
+ #include "pgpBase.h"
+
+ #include "pgpRMWOLock.h"
++
++ #ifdef __FreeBSD__
++ #define NULL 0 /* undefined for some reason */
++ #endif
+
+ #if PGP_UNIX_SOLARIS
+ /*
diff --git a/security/pgp6/files/patch-ah b/security/pgp6/files/patch-ah
new file mode 100644
index 000000000000..14df73baac0b
--- /dev/null
+++ b/security/pgp6/files/patch-ah
@@ -0,0 +1,19 @@
+*** libs/pgpcdk/priv/crypto/bignum/Makefile.in 2000/01/26 03:17:45 1.1
+--- libs/pgpcdk/priv/crypto/bignum/Makefile.in 2000/01/26 03:19:25 1.2
+***************
+*** 10,16 ****
+ # Architecture-dependent asm code
+ .SUFFIXES: .s
+ .s.o:
+! $(CC) -c $(CFLAGS) $<
+
+ DEFS_sparc=-DBNINCLUDE=bnisparc.h
+ OBJS_sparc=bnisparc.o
+--- 10,16 ----
+ # Architecture-dependent asm code
+ .SUFFIXES: .s
+ .s.o:
+! $(CC) -c -O -g $<
+
+ DEFS_sparc=-DBNINCLUDE=bnisparc.h
+ OBJS_sparc=bnisparc.o
diff --git a/security/pgp6/files/patch-ai b/security/pgp6/files/patch-ai
new file mode 100644
index 000000000000..6e06b0d6a4c0
--- /dev/null
+++ b/security/pgp6/files/patch-ai
@@ -0,0 +1,25 @@
+*** libs/pgpcdk/priv/crypto/bignum/bni80386_aout.s 2000/01/26 03:23:29 1.1
+--- libs/pgpcdk/priv/crypto/bignum/bni80386_aout.s 2000/01/26 03:23:59 1.2
+***************
+*** 16,24 ****
+
+ # Different assemblers have different conventions here
+ # These conventions are for a.out format assembler
+! align4=2 # could be 2 or 4
+! align8=3 # could be 3 or 8
+! align16=4 # cound be 4 or 16
+
+
+ .text
+--- 16,26 ----
+
+ # Different assemblers have different conventions here
+ # These conventions are for a.out format assembler
+!
+! # Changed from 2,3,4 to 4,8,16 for FreeBSD
+! align4=4 # could be 2 or 4
+! align8=8 # could be 3 or 8
+! align16=16 # cound be 4 or 16
+
+
+ .text
diff --git a/security/pgp6/files/patch-aj b/security/pgp6/files/patch-aj
new file mode 100644
index 000000000000..60ebe9025049
--- /dev/null
+++ b/security/pgp6/files/patch-aj
@@ -0,0 +1,15 @@
+*** libs/pgpcdk/pub/include/pgpSockets.h 2000/01/26 03:10:46 1.1.1.1
+--- libs/pgpcdk/pub/include/pgpSockets.h 2000/01/26 03:13:58 1.1.1.2
+***************
+*** 30,35 ****
+--- 30,39 ----
+ # include <netdb.h>
+ #endif
+
++ #ifdef __FreeBSD__
++ # include <sys/ioctl.h> /* Need FIONREAD */
++ #endif
++
+ #if PGP_WIN32
+ # include <winsock.h>
+ #endif
diff --git a/security/pgp6/files/patch-ak b/security/pgp6/files/patch-ak
new file mode 100644
index 000000000000..bb074fa23891
--- /dev/null
+++ b/security/pgp6/files/patch-ak
@@ -0,0 +1,70 @@
+*** libs/pgpcdk/priv/networklib/keyserver/CCRSEntrustServer.cpp 2000/01/26 03:10:44 1.1.1.1
+--- libs/pgpcdk/priv/networklib/keyserver/CCRSEntrustServer.cpp 2000/01/26 03:13:47 1.1.1.2
+***************
+*** 147,153 ****
+ if (! PGPKeySetRefIsValid(inCAsKeySet)) {
+ ThrowPGPError_(kPGPError_OptionNotFound);
+ }
+! if (accumulatedCRLs == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ pgpErr = PGPGetCRLDistributionPoints(inCAKey, inCAsKeySet, &numPoints, &points,
+--- 147,153 ----
+ if (! PGPKeySetRefIsValid(inCAsKeySet)) {
+ ThrowPGPError_(kPGPError_OptionNotFound);
+ }
+! if (accumulatedCRLs == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ pgpErr = PGPGetCRLDistributionPoints(inCAKey, inCAsKeySet, &numPoints, &points,
+***************
+*** 173,179 ****
+ #if PGP_COMPILER_SUN
+ pgpCopyMemory(static_cast<PGPByte *>(crl), static_cast<PGPByte *>(accumulatedCRLs) + accumulatedSize, crlSize);
+ #else
+! pgpCopyMemory(crl, static_cast<PGPByte *>(accumulatedCRLs) + accumulatedSize, crlSize);
+ #endif
+ accumulatedSize += crlSize;
+ currPoint += *currPointSize;
+--- 173,179 ----
+ #if PGP_COMPILER_SUN
+ pgpCopyMemory(static_cast<PGPByte *>(crl), static_cast<PGPByte *>(accumulatedCRLs) + accumulatedSize, crlSize);
+ #else
+! pgpCopyMemory((void *) crl, static_cast<PGPByte *>(accumulatedCRLs) + accumulatedSize, crlSize);
+ #endif
+ accumulatedSize += crlSize;
+ currPoint += *currPointSize;
+***************
+*** 215,221 ****
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64EncodedBufferSize(inMessageLength),
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ encodedSize = Base64Encode( static_cast<const PGPByte *>(inMessage),
+--- 215,221 ----
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64EncodedBufferSize(inMessageLength),
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ encodedSize = Base64Encode( static_cast<const PGPByte *>(inMessage),
+***************
+*** 226,232 ****
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxURLEncodedBufferSize(encodedSize) + bufSize,
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ strcpy(urlEncodedBuffer, kMessagePrefix);
+--- 226,232 ----
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxURLEncodedBufferSize(encodedSize) + bufSize,
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ strcpy(urlEncodedBuffer, kMessagePrefix);
diff --git a/security/pgp6/files/patch-al b/security/pgp6/files/patch-al
new file mode 100644
index 000000000000..2f61c8720fbd
--- /dev/null
+++ b/security/pgp6/files/patch-al
@@ -0,0 +1,31 @@
+*** libs/pgpcdk/priv/networklib/keyserver/CHTTPKeyServer.cpp 2000/01/26 03:10:44 1.1.1.1
+--- libs/pgpcdk/priv/networklib/keyserver/CHTTPKeyServer.cpp 2000/01/26 03:13:48 1.1.1.2
+***************
+*** 341,353 ****
+ tempStorage = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ kTempStorageSize,
+ kPGPMemoryMgrFlags_None));
+! if (tempStorage == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ buffer = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ result + 1,
+ kPGPMemoryMgrFlags_None));
+! if (buffer == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ socketResult = PGPReceive( mSocket,
+--- 341,353 ----
+ tempStorage = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ kTempStorageSize,
+ kPGPMemoryMgrFlags_None));
+! if (tempStorage == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ buffer = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ result + 1,
+ kPGPMemoryMgrFlags_None));
+! if (buffer == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ socketResult = PGPReceive( mSocket,
diff --git a/security/pgp6/files/patch-am b/security/pgp6/files/patch-am
new file mode 100644
index 000000000000..b3303052c11b
--- /dev/null
+++ b/security/pgp6/files/patch-am
@@ -0,0 +1,36 @@
+*** libs/pgpcdk/priv/networklib/keyserver/CHTTPPGPKeyServer.cpp 2000/01/26 03:10:44 1.1.1.1
+--- libs/pgpcdk/priv/networklib/keyserver/CHTTPPGPKeyServer.cpp 2000/01/26 03:13:48 1.1.1.2
+***************
+*** 92,98 ****
+ path = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ strlen(kQueryPrefix) + strlen(query) + 1,
+ kPGPMemoryMgrFlags_None));
+! if (path == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ sprintf(path, "%s%s", kQueryPrefix, static_cast<char *>(query));
+--- 92,98 ----
+ path = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ strlen(kQueryPrefix) + strlen(query) + 1,
+ kPGPMemoryMgrFlags_None));
+! if (path == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ sprintf(path, "%s%s", kQueryPrefix, static_cast<char *>(query));
+***************
+*** 188,194 ****
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxURLEncodedBufferSize(bufSize) + postPrefixSize,
+ kPGPMemoryMgrFlags_None));
+! if (urlEncodedBuffer == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ strcpy(urlEncodedBuffer, kPostPrefix);
+--- 188,194 ----
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxURLEncodedBufferSize(bufSize) + postPrefixSize,
+ kPGPMemoryMgrFlags_None));
+! if (urlEncodedBuffer == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ strcpy(urlEncodedBuffer, kPostPrefix);
diff --git a/security/pgp6/files/patch-an b/security/pgp6/files/patch-an
new file mode 100644
index 000000000000..3b149f2b1917
--- /dev/null
+++ b/security/pgp6/files/patch-an
@@ -0,0 +1,220 @@
+*** libs/pgpcdk/priv/networklib/keyserver/CHTTPXcertServer.cpp 2000/01/26 03:10:44 1.1.1.1
+--- libs/pgpcdk/priv/networklib/keyserver/CHTTPXcertServer.cpp 2000/01/26 03:13:49 1.1.1.2
+***************
+*** 89,95 ****
+ digest = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxDigestedKeyBufferSize(),
+ kPGPMemoryMgrFlags_None));
+! if (digest == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ digestSize = DigestKey(inCAKey, digest);
+--- 89,95 ----
+ digest = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxDigestedKeyBufferSize(),
+ kPGPMemoryMgrFlags_None));
+! if (digest == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ digestSize = DigestKey(inCAKey, digest);
+***************
+*** 98,104 ****
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64EncodedBufferSize(inBufferSize),
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ bufSize = Base64Encode( static_cast<const PGPByte *>(inBuffer),
+--- 98,104 ----
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64EncodedBufferSize(inBufferSize),
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ bufSize = Base64Encode( static_cast<const PGPByte *>(inBuffer),
+***************
+*** 109,115 ****
+ cnk = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ cnkSize,
+ kPGPMemoryMgrFlags_None));
+! if (cnk == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ pgpErr = PGPGetKeyPropertyBuffer( inRequestKey,
+--- 109,115 ----
+ cnk = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ cnkSize,
+ kPGPMemoryMgrFlags_None));
+! if (cnk == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ pgpErr = PGPGetKeyPropertyBuffer( inRequestKey,
+***************
+*** 121,127 ****
+ encodedCNK = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxHexEncodedBufferSize(cnkSize),
+ kPGPMemoryMgrFlags_None));
+! if (encodedCNK == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ cnkSize = HexEncode(cnk, cnkSize, encodedCNK);
+--- 121,127 ----
+ encodedCNK = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxHexEncodedBufferSize(cnkSize),
+ kPGPMemoryMgrFlags_None));
+! if (encodedCNK == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ cnkSize = HexEncode(cnk, cnkSize, encodedCNK);
+***************
+*** 131,137 ****
+ strlen(kCA) + digestSize + strlen(kCNK) + cnkSize
+ + strlen(kPKCS10_input) + GetMaxURLEncodedBufferSize(bufSize),
+ kPGPMemoryMgrFlags_None));
+! if (post == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ postSize = sprintf(post, "%s%s%s%s%s", kCA, static_cast<char *>(digest), kCNK,
+--- 131,137 ----
+ strlen(kCA) + digestSize + strlen(kCNK) + cnkSize
+ + strlen(kPKCS10_input) + GetMaxURLEncodedBufferSize(bufSize),
+ kPGPMemoryMgrFlags_None));
+! if (post == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ postSize = sprintf(post, "%s%s%s%s%s", kCA, static_cast<char *>(digest), kCNK,
+***************
+*** 196,202 ****
+ path = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ strlen(prefix) + strlen(query) + 1,
+ kPGPMemoryMgrFlags_None));
+! if (path == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ sprintf(path, "%s%s", prefix, static_cast<char *>(query));
+--- 196,202 ----
+ path = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ strlen(prefix) + strlen(query) + 1,
+ kPGPMemoryMgrFlags_None));
+! if (path == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ sprintf(path, "%s%s", prefix, static_cast<char *>(query));
+***************
+*** 258,271 ****
+ digest = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxDigestedKeyBufferSize(),
+ kPGPMemoryMgrFlags_None));
+! if (digest == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ digestSize = DigestKey(inCAKey, digest);
+ path = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ strlen(prefix) + digestSize + 1,
+ kPGPMemoryMgrFlags_None));
+! if (path == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ sprintf(path, "%s%s", prefix, static_cast<char *>(digest));
+--- 258,271 ----
+ digest = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxDigestedKeyBufferSize(),
+ kPGPMemoryMgrFlags_None));
+! if (digest == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ digestSize = DigestKey(inCAKey, digest);
+ path = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ strlen(prefix) + digestSize + 1,
+ kPGPMemoryMgrFlags_None));
+! if (path == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ }
+ sprintf(path, "%s%s", prefix, static_cast<char *>(digest));
+***************
+*** 323,329 ****
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64EncodedBufferSize(bufSize),
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ bufSize = Base64Encode( static_cast<const PGPByte *>(buffer),
+--- 323,329 ----
+ PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64EncodedBufferSize(bufSize),
+ kPGPMemoryMgrFlags_None));
+! if (encodedBuffer == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ bufSize = Base64Encode( static_cast<const PGPByte *>(buffer),
+***************
+*** 351,357 ****
+ buffer = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ bufSize,
+ kPGPMemoryMgrFlags_None));
+! if (buffer == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ pgpErr = PGPFinalizeHash(hashContext, static_cast<char *>(buffer));
+--- 351,357 ----
+ buffer = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ bufSize,
+ kPGPMemoryMgrFlags_None));
+! if (buffer == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ pgpErr = PGPFinalizeHash(hashContext, static_cast<char *>(buffer));
+***************
+*** 400,406 ****
+ result = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ resultSize + 1,
+ kPGPMemoryMgrFlags_None));
+! if (result == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ pgpCopyMemory(inResult, static_cast<char *>(result), resultSize + 1);
+--- 400,406 ----
+ result = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ resultSize + 1,
+ kPGPMemoryMgrFlags_None));
+! if (result == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+ pgpCopyMemory(inResult, static_cast<char *>(result), resultSize + 1);
+***************
+*** 426,432 ****
+ decodedResult = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64DecodedBufferSize(end - found),
+ kPGPMemoryMgrFlags_None));
+! if (decodedResult == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+
+--- 426,432 ----
+ decodedResult = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64DecodedBufferSize(end - found),
+ kPGPMemoryMgrFlags_None));
+! if (decodedResult == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+
+***************
+*** 470,476 ****
+ result = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64DecodedBufferSize(end - found),
+ kPGPMemoryMgrFlags_None));
+! if (result == 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+
+--- 470,476 ----
+ result = static_cast<PGPByte *>(PGPNewData( PGPGetContextMemoryMgr(mContext),
+ GetMaxBase64DecodedBufferSize(end - found),
+ kPGPMemoryMgrFlags_None));
+! if (result == (StPGPDataRef) 0) {
+ ThrowPGPError_(kPGPError_OutOfMemory);
+ };
+
diff --git a/security/pgp6/files/patch-ao b/security/pgp6/files/patch-ao
new file mode 100644
index 000000000000..1b6b9e15d38a
--- /dev/null
+++ b/security/pgp6/files/patch-ao
@@ -0,0 +1,15 @@
+*** libs/network/ldaplib/liblber/io.c 2000/01/26 03:10:31 1.1.1.1
+--- libs/network/ldaplib/liblber/io.c 2000/01/26 03:12:55 1.1.1.2
+***************
+*** 14,19 ****
+--- 14,23 ----
+ #include <stdio.h>
+ #include <ctype.h>
+
++ #ifdef __FreeBSD__
++ #include <sys/time.h>
++ #endif
++
+ #if PGPSOCKETSLDAP /* jason */
+ #include "pgpSocketsLDAP.h"
+
diff --git a/security/pgp6/files/patch-ap b/security/pgp6/files/patch-ap
new file mode 100644
index 000000000000..0df2d5b005da
--- /dev/null
+++ b/security/pgp6/files/patch-ap
@@ -0,0 +1,19 @@
+*** clients/pgp/cmdline/Makefile.in 2000/01/26 03:55:17 1.1
+--- clients/pgp/cmdline/Makefile.in 2000/01/26 03:55:41 1.2
+***************
+*** 51,57 ****
+ CFLAGS=@CFLAGS@
+ LDFLAGS=@LDFLAGS@
+
+! CFLAGS+= -g
+
+ TARGET=pgp
+
+--- 51,57 ----
+ CFLAGS=@CFLAGS@
+ LDFLAGS=@LDFLAGS@
+
+! CFLAGS+= -g -pthread
+
+ TARGET=pgp
+
diff --git a/security/pgp6/files/patch-aq b/security/pgp6/files/patch-aq
new file mode 100644
index 000000000000..693baa04b11c
--- /dev/null
+++ b/security/pgp6/files/patch-aq
@@ -0,0 +1,15 @@
+*** libs/network/ldaplib/include/ldap.h 2000/01/26 03:10:31 1.1.1.1
+--- libs/network/ldaplib/include/ldap.h 2000/01/26 03:12:53 1.1.1.2
+***************
+*** 90,95 ****
+--- 90,99 ----
+ #define GetThreadID pthread_self
+ #endif
+
++ #ifdef __FreeBSD__
++ #define GetThreadID pthread_self
++ #endif
++
+ #if PGP_MACINTOSH
+ #define Debug( level, fmt, arg1, arg2, arg3 ) {} /* Nothing */
+ #else
diff --git a/security/pgp6/pkg-descr b/security/pgp6/pkg-descr
index 37add9681f7a..26278a4a9057 100644
--- a/security/pgp6/pkg-descr
+++ b/security/pgp6/pkg-descr
@@ -1,20 +1,12 @@
-This is PGP 5.0, a significant step forward from 2.6.*
+This version of PGP combines many of the new features of PGP 5.0 with
+the command line interface of PGP 2.6.x.
-CHANGES:
+I ported this in an effort to get the newer code working under FreeBSD.
+The port is fairly straightforward, but my main focus was being able to build
+a functioning executable. Also, this is a port of beta code. It seems to
+work just fine, but keep in mind that it is a beta.
-There are a number of large changes from the 2.6.2 distribution. Most
-notable is that the command line has changed substantially. See
-the pgp(1) man page for a discussion of how to use the new command
-line.
+More information on this port can be found at:
+http://www.fate.com/projects/pgpport/
-Also, to allow easy interoperation with older versions on the same
-system, a number of filename changes have been made.
-
-NEW FEATURES:
-
-PGP 5.0 contains support for new encryption methods (most notably
-DSS/Diffie-Hellman), and built-in keyserver support. Also, the
-command line has been redesigned to be more Unix and scripting
-friendly.
-
-WWW: http://www.pgpi.com
+WWW: http://www.pgpi.org
diff --git a/security/pgp6/pkg-plist b/security/pgp6/pkg-plist
index a5acc8a38345..7cbdfdaf1683 100644
--- a/security/pgp6/pkg-plist
+++ b/security/pgp6/pkg-plist
@@ -1,14 +1 @@
-bin/pgp5
-@exec ln -fs %D/%F %B/pgpe
-@exec ln -fs %D/%F %B/pgps
-@exec ln -fs %D/%F %B/pgpv
-@exec ln -fs %D/%F %B/pgp_old
-@unexec rm %B/pgpe
-@unexec rm %B/pgps
-@unexec rm %B/pgpv
-@unexec rm %B/pgp_old
-bin/pgpk
-lib/libbn.a
-lib/libpgp.a
-lib/libpgptty.a
-lib/libsimple.a
+bin/pgp