|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #71642 Encrypt files using gnupg in php iis server?
Submitted: 2016-02-22 09:33 UTC Modified: 2016-09-18 04:22 UTC
Avg. Score:4.0 ± 1.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:-1 (-100.0%)
From: t dot tayyem at yahoo dot com Assigned: cmb (profile)
Status: No Feedback Package: IIS related
PHP Version: 5.6.18 OS: Windows NT (Windows 8 Business
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: t dot tayyem at yahoo dot com
New email:
PHP Version: OS:


 [2016-02-22 09:33 UTC] t dot tayyem at yahoo dot com
I've faced the error

Warning: gnupg_import(): import failed " while importing the public key and I did not have any luck solving this issue , when use (iis server-win8 - php version 5.5.12) with (php-5.5-windows-extensions/php_gnupg-1.3.3-5.5-vc11-x86/).

The question is, can i use php_gnupg (PGP (Pretty Good Privacy)) with IIS server to encrypted file ?

php_gnupg is a compatible with iis server !!!!


This problem does not appear when use XAMPP sever.

Test script:
$res = gnupg_init();
$public_key_sender = file_get_contents('public_key_sender.asc', true);
$private_key_sender = file_get_contents('public_key_sender.asc', true);
$private_key_sender_ = gnupg_import($res,$private_key_sender);
$public_key_sender_ = gnupg_import($res,$public_key_sender);

Expected result:
when use iis server (php version 5.5.12)
( ! ) Warning: gnupg_import(): import failed in C:\inetpub\wwwroot\index.php on line 18

Actual result:
when use xampp server (php version 5.5.12)
    [imported] => 0
    [unchanged] => 1
    [newuserids] => 0
    [newsubkeys] => 0
    [secretimported] => 0
    [secretunchanged] => 0
    [newsignatures] => 0
    [skippedkeys] => 0
    [fingerprint] => 94E803482C486876AEFB6A3B4EACA1AE3C37066D


gnupg-iis (last revision 2016-02-22 09:41 UTC by t dot tayyem at yahoo dot com)

Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2016-09-08 22:56 UTC]
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2016-09-08 22:56 UTC]
Please don't file non-security related tickets for PHP versions
which are no more actively supported[1] - PHP 5.5 is not actively
supported anymore as of July 2015.

So please try again with an actively supported PHP version, and
make sure that you have error_reporting set to E_ALL and to post
*all* notices/warnings etc. thrown by PHP. Furthermore please post
a self-contained reproduce script, if possible.

And, of course, make sure, that you don't read the contents of the
same file for the public and the private key:

> $public_key_sender = file_get_contents('public_key_sender.asc', true);
> $private_key_sender = file_get_contents('public_key_sender.asc', true);

[1] <>
 [2016-09-18 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 17 04:01:28 2024 UTC