Page MenuHome GnuPG
Feed Advanced Search

Jun 13 2016

gniibe added a comment to T2371: gnupg 2.1, gpg-agent crashing on 'assertion failed' (OS X, Homebrew).

I think that it is (long standing) bug in estream.c. Please see the attached
patch for a possible fix.
The enhancement in gnupg, the commit of 12af263 does READ then WRITE with
estream, and it reveals this bug.

Jun 13 2016, 7:10 AM · gpgrt, Bug Report
gniibe set Version to 1.22 on T2371: gnupg 2.1, gpg-agent crashing on 'assertion failed' (OS X, Homebrew).
Jun 13 2016, 7:10 AM · gpgrt, Bug Report
gniibe added a comment to T1675: gpg --verify has race conditions when used concurrently.

Finally, I managed to reproduce the same (I suppose) situation.
Please see: https://lists.gnupg.org/pipermail/gnupg-devel/2016-June/031211.html
It is READ vs. WRITE race condition.

Jun 13 2016, 4:39 AM · gnupg, Bug Report

Jun 10 2016

gniibe added a comment to T1675: gpg --verify has race conditions when used concurrently.

I think that this patch improve the situation.
It moves the creation of the hash table to the place where it creates version
record (holding the lock).

Jun 10 2016, 7:56 AM · gnupg, Bug Report
gniibe added a comment to T1675: gpg --verify has race conditions when used concurrently.

D205: 846_gpg14-create_hashtable-fix.diff

Jun 10 2016, 7:56 AM · gnupg, Bug Report

Jun 9 2016

gniibe added a comment to T1675: gpg --verify has race conditions when used concurrently.

Thank you for update.
msg8431 seems to be another race condition. I only fixed one race in 2015.

My saying in T1675 (gniibe on May 25 2015, 07:38 AM / Roundup) sounds wrong (now, for me).
For example, create_hashtable does lseek to SEEK_END.
When some another process is adding new entry (say, also calling
create_hashtable), we have a valid race condition here.
I mean,

(1) process A calls lseek with SEEK_END, seek goes to a point.
    Then, context switch.
(2) process B calls lseek with SEEK_END. seek goes same point as A.
(3) process B update info using the point.  context switch to A.
(4) process A wrongly overrides info using the point.
    It results inconsistent data.
Jun 9 2016, 4:21 AM · gnupg, Bug Report
gniibe added a comment to T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!".

It was fixed in db1ecc8212defdd183abbb6b1407fcc8d2dc9552 for 2.1.
In 2.1, HDRLEN=0 for all callers, so, there will be no same "Ohhhh jeeee" any more.

In 1.4 and 2.0, HDRLEN is used as a hint. There is no need to change 1.4 and
2.0. Detail is described in:
https://lists.gnupg.org/pipermail/gnupg-devel/2016-June/031178.html

Jun 9 2016, 12:56 AM · Bug Report, gnupg, Duplicate
gniibe closed T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!" as Resolved.
Jun 9 2016, 12:56 AM · Bug Report, gnupg, Duplicate
gniibe removed a project from T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!": In Progress.
Jun 9 2016, 12:56 AM · Bug Report, Duplicate, gnupg
gniibe added a project to T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!": Unreleased.
Jun 9 2016, 12:56 AM · Bug Report, Duplicate, gnupg

Jun 2 2016

gniibe added a comment to T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!".

In 1.4 and 2.0, --import just copies the block, so the bug doesn't hit. In 2.1,
when it tries to write to keybox, the bug hits.

Jun 2 2016, 6:57 AM · Bug Report, Duplicate, gnupg
gniibe added a comment to T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!".

The check what Neal introduced is somehow orthogonal to the change of mine.

The key in question, there is a User ID packet of length >= 256 (because he
include ssh key string in his User ID).
In the code of build-packet.c, gpg assumed the length of User ID is < 256 and it
is hard coded to have header length 2.
With the check (in gpg 2.1), it causes an error. I think that, in gpg 1.4 and
2.0, gpg creates malformed packet with incorrect length (LSB of the length).

Jun 2 2016, 1:50 AM · Bug Report, Duplicate, gnupg

Jun 1 2016

gniibe added a comment to T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!".

I don't know the reason, but User ID length is hardcoded.

diff --git a/g10/build-packet.c b/g10/build-packet.c
index 4bfc2ac..1353a86 100644

  • a/g10/build-packet.c

+++ b/g10/build-packet.c
@@ -329,7 +329,7 @@ do_user_id( IOBUF out, int ctb, PKT_user_id *uid )

  }
else
  {
  • write_header2( out, ctb, uid->len, 2 );

+ write_header2( out, ctb, uid->len, 0 );

    rc = iobuf_write( out, uid->name, uid->len );
  }
return rc;
Jun 1 2016, 1:49 PM · Bug Report, gnupg, Duplicate
gniibe claimed T2374: exporting public key fails with "Ohhhh jeeee: Can't encode length=294 in a 2 byte header!".
Jun 1 2016, 1:49 PM · Bug Report, gnupg, Duplicate

May 27 2016

gniibe added a comment to T2367: gnupg 2.1.12 doesn't properly detect libusb in FreeBSD.

D368: 838_gnupg-master-20160527.diff

May 27 2016, 1:45 AM · Bug Report, gnupg
gniibe added a comment to T2367: gnupg 2.1.12 doesn't properly detect libusb in FreeBSD.

Thank you for the report.
Indeed, the configure script has a bug.
Attached is a patch to fix this.

May 27 2016, 1:45 AM · Bug Report, gnupg
gniibe added a project to T2367: gnupg 2.1.12 doesn't properly detect libusb in FreeBSD: Restricted Project.
May 27 2016, 1:45 AM · Bug Report, gnupg
gniibe claimed T2367: gnupg 2.1.12 doesn't properly detect libusb in FreeBSD.
May 27 2016, 1:45 AM · Bug Report, gnupg

May 20 2016

gniibe added a comment to T2298: Unblocking a smartcard PIN not possible in 2.1.

Thank you for the version information which worked.

Speaking of the code of scdaemon, there is no difference for unblocking (by
resetcode and by admin) between 2.1.11/12 and 2.0.30.

Please note that there are two subcommands.

    admin -> passwd -> 2: unblocking by Admin
    unblock: unblocking by resetcode

Latter requires setting resetcode beforehand.

May 20 2016, 12:46 PM · Info Needed, gnupg, scd, Bug Report

May 19 2016

gniibe added a comment to T2298: Unblocking a smartcard PIN not possible in 2.1.

Here is another session after another three times failure.

This time, unblock by admin with Admin PIN.

$ gpg --card-edit

Reader ...........: Free Software Initiative of Japan Gnuk (FSIJ-1.1.9-87021534)
00 00
Application ID ...: D276000124010200FFFE870215340000
Version ..........: 2.0
Manufacturer .....: unmanaged S/N range
Serial number ....: 87021534
Name of cardholder: [not set]
Language prefs ...: [not set]
Sex ..............: unspecified
URL of public key : [not set]
Login data .......: [not set]
Signature PIN ....: not forced
Key attributes ...: rsa4096 rsa4096 rsa4096
Max. PIN lengths .: 127 127 127
PIN retry counter : 0 3 3
Signature counter : 6
Signature key ....: 6E9A 631F 1997 F37C 7F4E 9952 8916 1D16 AA0D B710

created ....: 2016-05-19 05:09:13

Encryption key....: 0138 70C9 FA89 986F 2784 31A9 8AAA 8F21 ABD4 A70C

created ....: 2016-05-19 05:09:13

Authentication key: B2FE 8DAF 9494 3320 760F 38E2 30F6 A992 6870 02D6

created ....: 2016-05-19 05:11:14

General key info..: pub rsa4096/AA0DB710 2016-05-19 Chuji Kunisada
<chuji@gniibe.org>
sec> rsa4096/AA0DB710 created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/ABD4A70C created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/687002D6 created: 2016-05-19 expires: never

                        card-no: FFFE 87021534

gpg/card> admin
Admin commands are allowed

gpg/card> passwd
gpg: OpenPGP card no. D276000124010200FFFE870215340000 detected

1 - change PIN
2 - unblock PIN
3 - change Admin PIN
4 - set the Reset Code
Q - quit

Your selection? 2

[ Admin PIN ]
[ New PIN ]
[ Repeat New PIN ]

PIN unblocked and new PIN set.

1 - change PIN
2 - unblock PIN
3 - change Admin PIN
4 - set the Reset Code
Q - quit

Your selection? q

gpg/card>

Reader ...........: Free Software Initiative of Japan Gnuk (FSIJ-1.1.9-87021534)
00 00
Application ID ...: D276000124010200FFFE870215340000
Version ..........: 2.0
Manufacturer .....: unmanaged S/N range
Serial number ....: 87021534
Name of cardholder: [not set]
Language prefs ...: [not set]
Sex ..............: unspecified
URL of public key : [not set]
Login data .......: [not set]
Signature PIN ....: not forced
Key attributes ...: rsa4096 rsa4096 rsa4096
Max. PIN lengths .: 127 127 127
PIN retry counter : 3 3 3
Signature counter : 6
Signature key ....: 6E9A 631F 1997 F37C 7F4E 9952 8916 1D16 AA0D B710

created ....: 2016-05-19 05:09:13

Encryption key....: 0138 70C9 FA89 986F 2784 31A9 8AAA 8F21 ABD4 A70C

created ....: 2016-05-19 05:09:13

Authentication key: B2FE 8DAF 9494 3320 760F 38E2 30F6 A992 6870 02D6

created ....: 2016-05-19 05:11:14

General key info..: pub rsa4096/AA0DB710 2016-05-19 Chuji Kunisada
<chuji@gniibe.org>
sec> rsa4096/AA0DB710 created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/ABD4A70C created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/687002D6 created: 2016-05-19 expires: never

                        card-no: FFFE 87021534

$

May 19 2016, 8:25 AM · Info Needed, gnupg, scd, Bug Report
gniibe added a project to T2298: Unblocking a smartcard PIN not possible in 2.1: Info Needed.
May 19 2016, 8:24 AM · Info Needed, gnupg, scd, Bug Report
gniibe changed Version from 2.1.11 to 2.1.11,2.1.12 on T2298: Unblocking a smartcard PIN not possible in 2.1.
May 19 2016, 8:24 AM · Info Needed, gnupg, scd, Bug Report
gniibe added a comment to T2298: Unblocking a smartcard PIN not possible in 2.1.

My case with Gnuk Token.
First, I intentionally input wrong PIN for singing three times.
Then, I invoke gpg --card-edit (with 2.1.2 on Debian experimental) to unblock
the token by resetcode.

$ gpg --card-edit

Reader ...........: Free Software Initiative of Japan Gnuk (FSIJ-1.1.9-87021534)
00 00
Application ID ...: D276000124010200FFFE870215340000
Version ..........: 2.0
Manufacturer .....: unmanaged S/N range
Serial number ....: 87021534
Name of cardholder: [not set]
Language prefs ...: [not set]
Sex ..............: unspecified
URL of public key : [not set]
Login data .......: [not set]
Signature PIN ....: not forced
Key attributes ...: rsa4096 rsa4096 rsa4096
Max. PIN lengths .: 127 127 127
PIN retry counter : 0 2 3
Signature counter : 6
Signature key ....: 6E9A 631F 1997 F37C 7F4E 9952 8916 1D16 AA0D B710

created ....: 2016-05-19 05:09:13

Encryption key....: 0138 70C9 FA89 986F 2784 31A9 8AAA 8F21 ABD4 A70C

created ....: 2016-05-19 05:09:13

Authentication key: B2FE 8DAF 9494 3320 760F 38E2 30F6 A992 6870 02D6

created ....: 2016-05-19 05:11:14

General key info..: pub rsa4096/AA0DB710 2016-05-19 Chuji Kunisada
<chuji@gniibe.org>
sec> rsa4096/AA0DB710 created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/ABD4A70C created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/687002D6 created: 2016-05-19 expires: never

                        card-no: FFFE 87021534

gpg/card> unblock
gpg: OpenPGP card no. D276000124010200FFFE870215340000 detected

[ Resetcode ]
[ New PIN ]
[ Repeat New PIN ]

PIN changed.

gpg/card>

Reader ...........: Free Software Initiative of Japan Gnuk (FSIJ-1.1.9-87021534)
00 00
Application ID ...: D276000124010200FFFE870215340000
Version ..........: 2.0
Manufacturer .....: unmanaged S/N range
Serial number ....: 87021534
Name of cardholder: [not set]
Language prefs ...: [not set]
Sex ..............: unspecified
URL of public key : [not set]
Login data .......: [not set]
Signature PIN ....: not forced
Key attributes ...: rsa4096 rsa4096 rsa4096
Max. PIN lengths .: 127 127 127
PIN retry counter : 3 3 3
Signature counter : 6
Signature key ....: 6E9A 631F 1997 F37C 7F4E 9952 8916 1D16 AA0D B710

created ....: 2016-05-19 05:09:13

Encryption key....: 0138 70C9 FA89 986F 2784 31A9 8AAA 8F21 ABD4 A70C

created ....: 2016-05-19 05:09:13

Authentication key: B2FE 8DAF 9494 3320 760F 38E2 30F6 A992 6870 02D6

created ....: 2016-05-19 05:11:14

General key info..: pub rsa4096/AA0DB710 2016-05-19 Chuji Kunisada
<chuji@gniibe.org>
sec> rsa4096/AA0DB710 created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/ABD4A70C created: 2016-05-19 expires: never

card-no: FFFE 87021534

ssb> rsa4096/687002D6 created: 2016-05-19 expires: never

                        card-no: FFFE 87021534

gpg/card> quit

Please note that 'unblock' subcommand is to unblock with resetcode.

May 19 2016, 8:24 AM · Info Needed, gnupg, scd, Bug Report

May 18 2016

gniibe added a comment to T2298: Unblocking a smartcard PIN not possible in 2.1.

For some reason, I can't reproduce your problem in 2.1.x. Isn't it a problem of
your smartcard implementation?
Please describe the specific version number of GnuPG which is possible to
unblock this particular implementation of smartcard.

May 18 2016, 1:18 PM · Info Needed, gnupg, scd, Bug Report

May 11 2016

gniibe added a comment to T2351: Segfault in gpg --update-trustdb.

Fixed in 83a90a916e8e2f8e44c3b11d11e1dd75f65a87fb (master).

May 11 2016, 12:41 PM · Bug Report, gnupg
gniibe closed T2351: Segfault in gpg --update-trustdb as Resolved.
May 11 2016, 12:41 PM · Bug Report, gnupg
gniibe added a project to T2351: Segfault in gpg --update-trustdb: Unreleased.
May 11 2016, 12:41 PM · Bug Report, gnupg
gniibe added a comment to T2351: Segfault in gpg --update-trustdb.

Thank you for the report and your cooperation.
At least, this fix is needed.

May 11 2016, 12:12 PM · Bug Report, gnupg
gniibe added a comment to T2351: Segfault in gpg --update-trustdb.

D367: 835_sig-check-correction.diff

May 11 2016, 12:12 PM · Bug Report, gnupg

May 10 2016

gniibe added a comment to T2349: Composing a private key from raw key material.

This will be useful for GnuPG itself. For example, currently in
gnupg/agent/command-ssh.c, we have a function ssh_receive_key which compose a
private key from 'ssh-add'. With this API, it will be cleaned up.

May 10 2016, 2:29 PM · libgcrypt, Feature Request
gniibe added projects to T2349: Composing a private key from raw key material: Feature Request, libgcrypt.
May 10 2016, 2:16 PM · libgcrypt, Feature Request

May 9 2016

gniibe added a comment to T2246: Regression: home dir no longer automatically created.

Fixed in all branches.

Master 2.1: d9f9b3be036747c9f55060aed47896f951bfb853
1.4: d957e4388f72581b1ec801613b5629b5ea3f586d
2.0: eb7806d63df63663170ba86f0673caa34b944c28

For some reason, the commit messages of 1.4 and 2.0 refers
master commit of 2f3e42047d17313eeb38d354048f343158402a8d.
Perhaps, I did in my repo and it was 2f3e420 and apply it to 1.4 and 2.0.
Then, I pushed 1.4, 2.0, and 2.1. and 2.1 was failed because of
non-fast-forward. Then I rebased for 2.1.

May 9 2016, 4:18 AM · Bug Report, gnupg
gniibe set Version to 1.4.20,2.0.29,2.1.11 on T2246: Regression: home dir no longer automatically created.
May 9 2016, 4:18 AM · Bug Report, gnupg

May 6 2016

gniibe added a project to T2347: Regression in cipher/ecc.c: Restricted Project.
May 6 2016, 10:21 AM · Bug Report, libgcrypt
gniibe set Version to 1.7.0 on T2347: Regression in cipher/ecc.c.
May 6 2016, 10:21 AM · Bug Report, libgcrypt
gniibe added a comment to T2347: Regression in cipher/ecc.c.

Cofactor is defined by the curve. I guess that the cofactor of the curve in
libaacs is 1. Although my patch includes the code which gets cofactor from key
parameters, the ECDSA computation itself doesn't use cofactor actually.

Well, I haven't expected there is a user who uses (flags param), because it was
mostly for our development. There must be more bugs around that...

May 6 2016, 10:21 AM · Bug Report, libgcrypt
gniibe added a comment to T2347: Regression in cipher/ecc.c.

Good catch.
Fixed in c7430aa752232aa690c5d8f16575a345442ad8d7.

May 6 2016, 6:25 AM · Bug Report, libgcrypt
gniibe claimed T2347: Regression in cipher/ecc.c.
May 6 2016, 6:25 AM · Bug Report, libgcrypt
gniibe removed a project from T2095: Stop installing gpg-zip(1): In Progress.
May 6 2016, 6:04 AM · Documentation, Bug Report, gnupg
gniibe closed T2095: Stop installing gpg-zip(1) as Resolved.
May 6 2016, 6:04 AM · Documentation, Bug Report, gnupg

May 3 2016

gniibe claimed T2260: npth resource locking not working on AIX.
May 3 2016, 11:05 AM · Bug Report, npth
gniibe added a comment to T2260: npth resource locking not working on AIX.

Thank you.
I think that it's better to use sem_init with pshared=1.
I'm sending my proposal patch to gnupg-devel.

May 3 2016, 11:05 AM · Bug Report, npth

May 2 2016

gniibe added a comment to T2306: Rare smartcard errors with gnupg master.

Another problem has been fixed in 6677d8b.
I intentionally set up more hubs from computer to the device to cause an error.
When an error occurred, scdaemon continued to report "Card error", even after I
inserted the device directly to the computer.
Now, it returns "No such device" for severe errors, and scdaemon can recover
from such errors.

May 2 2016, 9:04 AM · Bug Report, gnupg, scd

Apr 28 2016

gniibe added a comment to T2306: Rare smartcard errors with gnupg master.

The particular problem of T2306 (aheinecke on Apr 25 2016, 06:53 PM / Roundup) has been fixed in cb4fee8.

I think that it was not always reproducible because it depends on timing (only
when it detected an error at bulk_in, the problem happened). I'm not sure if
the difference of old/new libusb mattered for this problem.

Apr 28 2016, 5:53 AM · Bug Report, gnupg, scd
gniibe added a project to T2306: Rare smartcard errors with gnupg master: Restricted Project.
Apr 28 2016, 5:53 AM · Bug Report, gnupg, scd

Apr 26 2016

gniibe added a comment to T1671: libgpg-error 1.13 does not link on Solaris 10.

libgpg-error 1.22 is out with fix. Please test.

Apr 26 2016, 1:35 AM · gpgrt, Bug Report
gniibe added a comment to T1931: libgpg-error-1.18 all tests core on Solaris10 with gcc4.9.2.

libgpg-error 1.2.2 is out. Please test with it.

Apr 26 2016, 1:34 AM · Bug Report, gpgrt

Apr 22 2016

gniibe added a comment to T2306: Rare smartcard errors with gnupg master.

I'm reading the implementation of new libusb.
If I guess correctly, the picture of the problem would be:

  • New libusb somehow caches (or uses cache of kernel's) USB device list structures.
  • When the device is plugged off/on (or hardware failures), the cache should be

updated.

  • GnuPG's ccid-driver possibly keeps using staled data of USB device list.

I'll check the implementation detail, and try fixing this.
I think that current ccid-driver with new libusb has an issue for memory leaks
for device list, so, it should be reviewed and modified anyway.

It would be good if we could have a reproducible scenario.

Apr 22 2016, 1:53 AM · Bug Report, gnupg, scd

Apr 19 2016

gniibe claimed T2298: Unblocking a smartcard PIN not possible in 2.1.
Apr 19 2016, 6:41 AM · Info Needed, gnupg, scd, Bug Report
gniibe added a comment to T2298: Unblocking a smartcard PIN not possible in 2.1.

Please describe the interaction. IIUC, isn't it pinentry problem?
Did you input your PIN? For "2 - unblock PIN" operation, you need to
authenticate as admin, did you input your PIN for admin? Wasn't it a failure of
PIN input for admin or user, whatever?

Apr 19 2016, 6:41 AM · Info Needed, gnupg, scd, Bug Report
gniibe added a comment to T2282: Invalid flag adding encryption subkey with Curve 25519.

libgcrypt 1.7.0 is out. Please test with it.

Apr 19 2016, 6:26 AM · Not A Bug, Bug Report, gnupg

Apr 15 2016

gniibe added a comment to T2144: libgpg-error: assertion error on Solaris/sparc.

Thank you for your patch. Yes, we already located the issue is the alignment.
I think that it were good if the MTX were placed at the head. While your patch
works, it changes ABI of the lock object for existing archs, unfortunately.

I fixed the detection of Solaris in:
http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commit;h=f7a77c5c236ecec846de9be46703026f9b01008f

And I believe that the bug reported here had gone.
Please test current development master.

Apr 15 2016, 1:12 AM · Bug Report, gpgrt

Apr 6 2016

gniibe claimed T2306: Rare smartcard errors with gnupg master.
Apr 6 2016, 8:21 AM · Bug Report, gnupg, scd
gniibe added a comment to T2306: Rare smartcard errors with gnupg master.

Possible causes would be SUSPEND/RESUME of usb device.
Let me see about libusb implementation differences.

Apr 6 2016, 8:21 AM · Bug Report, gnupg, scd

Mar 23 2016

gniibe claimed T2285: decryption fails with "Missing item in object" even though private key is available.
Mar 23 2016, 3:52 AM · Info Needed, Bug Report, gnupg, scd
gniibe added a comment to T2285: decryption fails with "Missing item in object" even though private key is available.

Thank you for your report and the log, but it doesn't have useful information so
that I can debug.

The information of card reader is required, if the problem happens for specific
card reader only. Please include full log which includes card reader information.

Mar 23 2016, 3:52 AM · Info Needed, Bug Report, gnupg, scd
gniibe added projects to T2291: Smartcard interaction improvement (was: Shadowed private key design (for smartcard)): gnupg, Bug Report.
Mar 23 2016, 2:12 AM · Restricted Project, Feature Request, gnupg

Mar 8 2016

gniibe added a comment to T1931: libgpg-error-1.18 all tests core on Solaris10 with gcc4.9.2.

I think that I fixed this issue in master. If you have time, please test, from
git repo.

Mar 8 2016, 1:07 PM · Bug Report, gpgrt
gniibe added a project to T1931: libgpg-error-1.18 all tests core on Solaris10 with gcc4.9.2: Restricted Project.
Mar 8 2016, 1:07 PM · Bug Report, gpgrt
gniibe claimed T1931: libgpg-error-1.18 all tests core on Solaris10 with gcc4.9.2.
Mar 8 2016, 1:07 PM · Bug Report, gpgrt
gniibe removed a project from T1931: libgpg-error-1.18 all tests core on Solaris10 with gcc4.9.2: Info Needed.
Mar 8 2016, 1:07 PM · Bug Report, gpgrt
gniibe claimed T2234: Core dump while calling bkuptocard.
Mar 8 2016, 1:01 PM · Bug Report, gnupg
gniibe added a project to T2234: Core dump while calling bkuptocard: Restricted Project.
Mar 8 2016, 1:01 PM · Bug Report, gnupg
gniibe added a comment to T2234: Core dump while calling bkuptocard.

bkuptocard had been not implemented, but it was finally implemented in 2.1.11.
If any problem, please let us know.

Mar 8 2016, 1:01 PM · Bug Report, gnupg

Mar 1 2016

gniibe added a comment to T2144: libgpg-error: assertion error on Solaris/sparc.

Thank you for clarification. I didn't know that pkgsrc supports other
platforms. Now, I understand.

I changed more:
http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commitdiff;h=34b07146bbb0863436fc9381a84314b18bdfb807;hp=49655fb6ef39b307787e1b6e00c996f9c7db64f7

The intention is that USE_DOUBLE_FOR_ALIGNMENT for Solaris 32-bit version.
I thought that checking ILP32 worked (but not, in fact). I believe that LP64
checking works (at least with GCC).

Mar 1 2016, 2:32 AM · Bug Report, gpgrt

Feb 29 2016

gniibe added a comment to T2144: libgpg-error: assertion error on Solaris/sparc.

Let me clarify/confirm. Does it work on Solaris? And now do you speak for NetBSD?
My fix is specific to Solaris (no matter if it's Sparc or not). It doesn't
handle any issues for NetBSD.

I seems that Sparc GNU/Linux doesn't have this alignment issue, but (for me) it
is highly likely that sparc architecutre requires the alignment of 8-byte.

Feb 29 2016, 12:37 AM · Bug Report, gpgrt

Feb 26 2016

gniibe added a project to T2144: libgpg-error: assertion error on Solaris/sparc: Restricted Project.
Feb 26 2016, 2:28 AM · Bug Report, gpgrt
gniibe added a comment to T2144: libgpg-error: assertion error on Solaris/sparc.

Thank you for your report. Yes, it is the alignment issue.

Please try:
http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commit;h=5168b97fb5e2eebdc99b40f96f9b6289647e87d2

Feb 26 2016, 2:28 AM · Bug Report, gpgrt
gniibe added a comment to T2259: --key-gen failing on Solaris 10.

Reading the report, it seems for me that there is nothing we can do as GnuPG Team;
When poll/select returns 0 for /dev/random, it is natural for GnuPG (or any
applications) to wait.
If it is Solaris 10 kernel which changed the behaviour of /dev/random, it should
be fixed or it is better (for us) to know some way to workaround this change.

Feb 26 2016, 2:24 AM · gnupg, gnupg (gpg14), Bug Report
gniibe added a comment to T1671: libgpg-error 1.13 does not link on Solaris 10.

Fixed in
http://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commit;h=5168b97fb5e2eebdc99b40f96f9b6289647e87d2

Please test.

Feb 26 2016, 1:59 AM · gpgrt, Bug Report
gniibe added a project to T1671: libgpg-error 1.13 does not link on Solaris 10: Restricted Project.
Feb 26 2016, 1:59 AM · gpgrt, Bug Report
gniibe removed a project from T1671: libgpg-error 1.13 does not link on Solaris 10: Stalled.
Feb 26 2016, 1:59 AM · gpgrt, Bug Report

Feb 23 2016

gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

By "all zero", I mean that a limb can be with bits of all zeros, so that e =
ep[i] can be zero.

Feb 23 2016, 6:10 AM · Bug Report, libgcrypt
gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

D359: 783_mpi-pow-normalize-expo.diff

Feb 23 2016, 6:07 AM · Bug Report, libgcrypt
gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

Thank you very much. It is reproducible for me, too. I located the issue.
I think that it is reproducible for any libgcrypt (even < 1.5.3).
With the patch attached, problem seems to be gone.
Problem is that the DH exchange introduced in the commit fc4a969a in libssh2,
the EXPO argument is coming without normalization, so, count_leading_zeros
results undefined value on IA-32.
In libssh2, it's random bytes, so, it can be all 0.

Feb 23 2016, 6:07 AM · Bug Report, libgcrypt

Feb 22 2016

gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

If it is difficult for you to minimize your test case, as long as it is
reproducible, please let us have your test case. We'll try to figure out the bug.

Feb 22 2016, 6:38 AM · Bug Report, libgcrypt

Feb 17 2016

gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

I can't show you math proof at hand, but I'm confident enough J can't be negative.
This implementation of mpi_powm was introduced in October 2013.

libgcrypt 1.5.3 was the one with old implementation.

Feb 17 2016, 1:14 PM · Bug Report, libgcrypt
gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

Thank you for your experiment.
I suspect other cause(s). In the code itself, there is no possibility J can be
negative. However, it could be possible, in practice, when the stack is
corrupted because of wrong allocation of memory or by other threads.

Feb 17 2016, 12:45 AM · Bug Report, libgcrypt

Feb 16 2016

gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

When you get negative value for J on entry of the for loop, you can examine four
arguments to _gcry_mpi_powm. And then, you can write standalone program to
emulate it. Debugger or printf.

Feb 16 2016, 1:04 PM · Bug Report, libgcrypt
gniibe claimed T2256: (Near) endless loop in gcry_mpi_powm.
Feb 16 2016, 12:15 PM · Bug Report, libgcrypt
gniibe added a comment to T2256: (Near) endless loop in gcry_mpi_powm.

In what condition can J can be initialized < 0?
Do you have some idea?

Feb 16 2016, 12:15 PM · Bug Report, libgcrypt

Feb 12 2016

gniibe added a comment to T2246: Regression: home dir no longer automatically created.

Sorry, here it is.

Feb 12 2016, 6:32 AM · Bug Report, gnupg
gniibe added a comment to T2246: Regression: home dir no longer automatically created.

D347: 767_0001-g10-Make-sure-to-have-the-directory-for-trustdb-v3.patch

Feb 12 2016, 6:32 AM · Bug Report, gnupg
gniibe added a comment to T2246: Regression: home dir no longer automatically created.

D348: 766_0001-g10-Make-sure-to-have-the-directory-for-trustdb-v3.patch

Feb 12 2016, 1:59 AM · Bug Report, gnupg
gniibe added a comment to T2246: Regression: home dir no longer automatically created.

This would be final version.
If !create, we can let it return earlier.

Feb 12 2016, 1:59 AM · Bug Report, gnupg
gniibe added a comment to T2246: Regression: home dir no longer automatically created.

You are right to have the check against CREATE.
I'll include that check.

Feb 12 2016, 1:39 AM · Bug Report, gnupg

Feb 10 2016

gniibe added a project to T2246: Regression: home dir no longer automatically created: Restricted Project.
Feb 10 2016, 2:37 AM · Bug Report, gnupg
gniibe added a comment to T2246: Regression: home dir no longer automatically created.

Please try attached patch.
While I understand it's a regression (and it's urgent for you), I downgrade the
priority.
It will be soon in the repo.

Feb 10 2016, 2:37 AM · Bug Report, gnupg
gniibe added a comment to T2246: Regression: home dir no longer automatically created.

D350: 764_0001-g10-Make-sure-to-have-the-directory-for-trustdb.patch

Feb 10 2016, 2:37 AM · Bug Report, gnupg
gniibe lowered the priority of T2246: Regression: home dir no longer automatically created from High to Normal.
Feb 10 2016, 2:37 AM · Bug Report, gnupg
gniibe added a comment to T2246: Regression: home dir no longer automatically created.

Thank you for the report. Confirmed. It was my mistake, I didn't test the code
path with no homedir.

Feb 10 2016, 12:53 AM · Bug Report, gnupg
gniibe claimed T2246: Regression: home dir no longer automatically created.
Feb 10 2016, 12:53 AM · Bug Report, gnupg
gniibe closed T2150: Generating keys on OpenPGP card yields wrong public key as Resolved.
Feb 10 2016, 12:25 AM · Bug Report, gnupg, gnupg (gpg21)
gniibe removed a project from T2150: Generating keys on OpenPGP card yields wrong public key: Restricted Project.
Feb 10 2016, 12:25 AM · Bug Report, gnupg, gnupg (gpg21)
gniibe added a comment to T2074: Redeclaration of internal functions to use "external" typedef prevents build on AIX.

I believe 1.6.5 has no problem.

Feb 10 2016, 12:23 AM · Bug Report, libgcrypt
gniibe closed T2074: Redeclaration of internal functions to use "external" typedef prevents build on AIX as Resolved.
Feb 10 2016, 12:23 AM · Bug Report, libgcrypt
gniibe removed a project from T2074: Redeclaration of internal functions to use "external" typedef prevents build on AIX: Restricted Project.
Feb 10 2016, 12:23 AM · Bug Report, libgcrypt

Feb 3 2016

gniibe claimed T1671: libgpg-error 1.13 does not link on Solaris 10.
Feb 3 2016, 7:06 AM · gpgrt, Bug Report
gniibe added a comment to T1671: libgpg-error 1.13 does not link on Solaris 10.

I think that we could add -lrt in configure script.
Solaris also has a problem for lock object.

Its pthread_mutex_t seems have alignment of 8-byte.
In posix-lock-obj.h, we will have a padding after vers and the union u.
So, it fails at assert (!"sizeof lock obj");

Reference:
http://src.illumos.org/source/xref/illumos-gate/usr/src/uts/common/sys/types.h

Feb 3 2016, 7:06 AM · gpgrt, Bug Report

Jan 13 2016

gniibe added a comment to T1828: card-edit/fetch assumes signing key is master key and fails if not.

It would be different issue, but we have similar problem for 'fetch' failure
with an error message like:

gpg: key B00DC692: rejected by import filter" followed by "gpg: Total number
processed: 1

Jan 13 2016, 1:21 AM · Bug Report, gnupg