debian/0000755000000000000000000000000012162577601007175 5ustar debian/compat0000644000000000000000000000000212162577601010373 0ustar 9 debian/control0000644000000000000000000000145212162577601010602 0ustar Source: php-crypt-gpg Section: php Priority: optional Maintainer: Debian PHP PEAR Maintainers Uploaders: Joey Schulze , Prach Pongpanich Build-Depends: debhelper (>= 9), pkg-php-tools Build-Depends-Indep: php-pear Vcs-Git: git://anonscm.debian.org/pkg-php/php-crypt-gpg.git Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-php/php-crypt-gpg.git Homepage: http://pear.php.net/package/Crypt_GPG Standards-Version: 3.9.4 Package: php-crypt-gpg Architecture: all Depends: ${misc:Depends}, php-pear, gnupg Description: PHP PEAR module for encrypting and decrypting with GnuPG Crypt/GPG.php profides an object oriented interface to GNU Privacy Guard (GnuPG). This PEAR package is intended to facilitate public-key cryptography. debian/docs0000644000000000000000000000002212162577601010042 0ustar debian/sample.php debian/source/0000755000000000000000000000000012162577601010475 5ustar debian/source/format0000644000000000000000000000001412162577601011703 0ustar 3.0 (quilt) debian/gbp.conf0000644000000000000000000000024312162577601010613 0ustar [DEFAULT] upstream-branch = upstream-sid debian-branch = debian-sid pristine-tar = True [git-buildpackage] export-dir = ../build-area/ tarball-dir = ../tarballs/ debian/watch0000644000000000000000000000015612162577601010230 0ustar version=3 http://pear.php.net/package/Crypt_GPG http://download.pear.php.net/package/Crypt_GPG-([\d.RC]+).tgz debian/changelog0000644000000000000000000000501012162577601011043 0ustar php-crypt-gpg (1.3.2-1) unstable; urgency=low * New upstream release * Now using PKG-PHP-PEAR team as maintainer * Switch to pkg-php-tools and dh-sequencer - Drop debian/{postinst,prerm} file (Closes: #689324) * Add Depends on misc-depends * Add myself as uploader * Switch VCS to git (Closes: #638505) * Switch to 3.0 (quilt) source format (Closes: #664382) * Switch debian/copyright to format 1.0 * Bump debhelper compat to 9 * Bump Standards-Version to 3.9.4 -- Prach Pongpanich Thu, 20 Jun 2013 21:15:34 +0700 php-crypt-gpg (1.1.1-1) unstable; urgency=low * New upstream source * Corrects problem with specifying trustdb -- Joey Schulze Sat, 19 Jun 2010 17:06:22 +0200 php-crypt-gpg (1.1.0-1) unstable; urgency=low * Change section from web to php to accomplish an override disparity * New upstream version -- Joey Schulze Sat, 15 May 2010 20:54:46 +0200 php-crypt-gpg (1.0.0-2) unstable; urgency=low * Add possibility to add --textmode to signing command line, required for digitally signing mail [patches/sign-textmode.dpatch], extracted from PEAR feature request -- Joey Schulze Sat, 23 Jan 2010 11:03:11 +0100 php-crypt-gpg (1.0.0-1) unstable; urgency=low * New upstream version . Includes improved subkeys handling * Final release 1.0.0 * Removed subkeys patch since this problem is fixed upstream -- Joey Schulze Sun, 25 Jan 2009 09:39:09 +0100 php-crypt-gpg (1.0.0~RC1-3) unstable; urgency=low * Removed pear post-install installation call until draf PHP policy is fixed, this will make the package installable again -- Joey Schulze Tue, 13 Jan 2009 22:15:06 +0100 php-crypt-gpg (1.0.0~RC1-2) unstable; urgency=low * Added a simple example * Added calls to pear install/uninstall to the postinst/prerm script as per draft PHP policy, section 4.2.2 -- Joey Schulze Wed, 07 Jan 2009 17:21:26 +0100 php-crypt-gpg (1.0.0~RC1-1) unstable; urgency=low * Initial packaging * Improved rules file by dynamically importing dpatch snippets from dpatch * Search for keys with passphrases not only for the particularly used subkey but also for the main key id in case the passphrase is stored under the main key id [01-not_only_subkeys.dpatch] * Remove executable bit for patches on clean target -- Joey Schulze Fri, 26 Dec 2008 20:37:24 +0100 debian/sample.php0000644000000000000000000000640612162577601011175 0ustar // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation; either version 2 of the License, or // (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License along // with this program; if not, write to the Free Software Foundation, Inc., // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. require_once 'Crypt/GPG.php'; function gpg_create($info) { if (!array_key_exists('name', $info) || !array_key_exists('pass', $info)) return false; if (!array_key_exists('type', $info)) $info['type'] = 'RSA'; if (!array_key_exists('length', $info)) $info['length'] = 2048; if (!array_key_exists('sublength', $info)) $info['sublength'] = 2048; if (!array_key_exists('mail', $info)) $info['mail'] = 'root@localhost'; if (($tmpname = tempnam('/tmp', 'gpg')) === false) return false; if (($output = tempnam('/tmp', 'gpg')) === false) return false; if (($f = fopen($tmpname, "w")) === false) { unlink($tmpname); return false; } fwrite($f, sprintf("Key-Type: %s\n", $info['type'])); fwrite($f, sprintf("Key-Length: %d\n", $info['length'])); fwrite($f, "Subkey-Type: ELG-E\n"); fwrite($f, sprintf("Subkey-Length: %d\n", $info['sublength'])); fwrite($f, sprintf("Name-Real: %s\n", $info['name'])); fwrite($f, sprintf("Name-Email: %s\n", $info['mail'])); fwrite($f, "Expire-Date: 0\n"); fwrite($f, sprintf("Passphrase: %s\n", $info['pass'])); fwrite($f, "%commit\n"); fclose($f); if (system("gpg --batch --gen-key $tmpname > /dev/null 2> $output") === false) { unlink($tmpname); unlink($output); return false; } if (($f = fopen($output, "r")) === false) { unlink($tmpname); unlink($output); return false; } $key = ''; while (!feof($f)) { $line = fgets($f, 500); echo $line."\n"; if (preg_match('/^gpg: key ([0-9A-F]{8}) .*/', $line, $matches) > 0) { $key = $matches[1]; } } fclose($f); system("gpg --update-trustdb 2> /dev/null"); unlink($tmpname); return $key; } # // Neuen Schlüssel erzeugen # $r = gpg_create(array('name' => 'Real Name', # 'mail' => 'user@doma.in', # #'length' => 2048, # #'sublength' => 2048, # 'pass' => 'Passphrase')); # # // encrypt something # $gpg = new Crypt_GPG(); # $gpg->addEncryptKey('0xB62F3700'); # $gpg->encryptFile('/tmp/OT16752740690.ps', 'OT16752740690.ps.gpg', false); // decrypt file $gpg = new Crypt_GPG(); $gpg->addDecryptKey('0xB62F3700', 'Passphrase'); $gpg->decryptFile('OT16752740690.ps.gpg', 'decoded.ps'); # // encrypt and decrypt text # $clear = "Ein geheimer Text"; # printf("%s\n", $clear); # $gpg = new Crypt_GPG(); # $gpg->addEncryptKey('0xB62F3700'); # $enc = $gpg->encrypt($clear); # printf("%s\n", $enc); # $gpg->addDecryptKey('0xB62F3700', 'Passphrase'); # $dec = $gpg->decrypt($enc); # printf("%s\n", $dec); ?> debian/copyright0000644000000000000000000000417712162577601011141 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: Crypt_GPG Upstream-Contact: Nathan Fredrickson Michael Gauthier Source: http://pear.php.net/package/Crypt_GPG/download Files: debian/* Copyright: 2008-2013, Joey Schulze 2013, Prach Pongpanich License: GPL-2+ This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 2 of the License, or (at your option) any later version. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. . You should have received a copy of the GNU General Public License along with this package; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA . On Debian systems, the complete text of the GNU General Public License 2 can be found in "/usr/share/common-licenses/GPL-2". Files: * Copyright: 2005-2011 silverorange License: LGPL-2.1+ This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. . This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. . You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . On Debian systems, the complete text of the GNU Library General Public License version 2 can be found in "/usr/share/common-licenses/LGPL-2.1". debian/NMU-Disclaimer0000644000000000000000000000357312162577601011641 0ustar Non Maintainer Upload of this Package ------------------------------------- If you plan to work on an NMU for this package, read the following closely. It can save you and me some grief. 1. At first, contact the maintainer (i.e. send a mail to joey@debian.org, do not cc or bounce a mail, send a plain mail, not copied to any mailing list or the BTS) and ask about the status of the bug you are considering to work on. 2. In this mail include all information relevant for this problem, i.e. include a description of the bug and not only its bug number. 3. If the maintainer is not able or willing to fix the problem or does not respond within four days, continue with step 4. 4. Work on the bug and prepare a patch. Do not upload into the Debian archive. 5. Send the entire patch, together with enough explanations, to the maintainer for reviewing and ask him for permission of an NMU using this patch. 6. IF AND ONLY IF the maintainer approves the patch (or doesn't respond within four days), upload the NMU to the incoming directory and send the patch to the BTS. If the NMU is not approved, go back to 4. or add the NMU to your homepage, but do not upload it to the Debian archive. 7. Properly sized and well-written patches sent to the BTS are always appreciated, even if they are rejected later. They demonstrate a potential solution which could probably improved into a real solution. 8. NEVER change the way a package is maintained in an NMU, i.e. don't remove dh_* stuff or switch to dh_* respectively. This rule applies to all NMU's, not only to an NMU for this package. These rules always apply. They even apply if somebody declares NMUs as ok and reduces regular NMU rules to a delay of zero days. Unless I'm on vacation or on a show I am reachable via mail, so there is hardly a reason not to contact me. debian/rules0000755000000000000000000000177712162577601010271 0ustar #! /usr/bin/make -f # Copyright 1994-99,2001,2008,2009 joey@infodrom.org (Joey Schulze) # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License along # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. %: dh $@ --buildsystem=phppear --with phppear override_dh_auto_configure: dh_auto_configure -O--buildsystem=phppear # Remove references of ChangeLog sed -i 's@^.*ChangeLog.*$$@@' */package.xml