#14 ✓released
Support

Keys or messages without line breaks can not be operated

Reported by Support | December 19th, 2011 @ 07:54 PM | in 0.6 (closed)

Same issue: #38, #145

Assigned to Tender discussion #49.

Enhance Libmacgpg or GKA to accept weird keys like this one: http://www.snort.org/pub-keys/public_key_290 (it's valid but needs line manual breaks)

Comments and changes to this ticket

  • Alex (via GPGTools)

    Alex (via GPGTools) December 19th, 2011 @ 07:56 PM

    Ok, there are line breaks...

    -----BEGIN PGP PUBLIC KEY BLOCK----- Version: GnuPG v1.4.9 (GNU/Linux) mQGiBExVzKURBADfX1KyatlazVGCpNkHLbWN2gAxCmczqkLzbRyHDhb2tWzvjEIJ tnyOEsT5/qMJhwZNzj4yn8MvDJjG/c+4/m8/c/sYCzAnHPaL1sjD9FHpr0joYUig x3PtKZnSM5H4K38tRbunuyCpXhew9Kr1LUdjexJJiZJ4nAsZcErlJH0lNwCgth1i BEriGwurm+S58KNg7yJ/PO8D+gOP0CBYqLiCByqqTuXf9OCPgSzG3Z8lo+Isyyui AhPCb/20C9ZDVtnlAtrFqT/3XbhTJDjFczKzk1LNzlH+JoTQE1b0I2iH2UDuCrUl 7u0fqe6xaJIcKsk0lg7z8bzqzJni1FMYSlyOrNnRY/7sOmZWsksuK6OOqHBrsndS 6XKsBADZ5Pv7CfHU6qG146/4hp/Efx/GhcHHtA7IJ2+ETxSNt0ZjdssykIrpfI80 aELf8Ce7LlwvMGDhzvoe2AhyZYDW86M2CN0tXU43oC+l040WAJB8cNp/6TXfR7I7 rRVo9PcHT9VKVfy/ElwhqLraJOkLJppdS0cDD/kVHQvVWuZY7bRIU25vcnQgUmVs ZWFzZSBUZWFtIChTbm9ydCBSZWxlYXNlIFRlYW0gc2lnbmluZyBrZXkpIDxyZWxl YXNlc0Bzbm9ydC5vcmc+iGYEExECACYFAkxVzKUCGwMFCQPCZwAGCwkIBwMCBBUC CAMEFgIDAQIeAQIXgAAKCRDYNAwGQ1+hlf3yAKCQGu/O3sPqF/wNftCvfwO84X7P EACfXmH6UYfwN3GXoEFBUvPTBBZlPOCIRgQQEQIABgUCTFXOFQAKCRBEJgn/yoet KMRxAKC1Mg754t1DfdXHmG+Na+iHlHTBFgCgnPTOeJxTamIxCh6ODr1DXoUATGq5 Ag0ETFXMpRAIAMSXeATAOpT/KOQfaX+bn4ohgETZVUwsZMTjTX5MKBsGn3WYz+t2 ZGtv8d9R68p6RIe9ZmFPqcauuuPgaJo/v7fbaIdNNeEGn2/EBNDF9nHo7y3/vhfi yTXhogVJBizjWNDdrcaM1IYNbtptq6RBKvzDPZ//2+sX2fbb0XxB5SNZF8HDRdl8 CDK79VA651JAoOBI7n6FLvBIurFkSEKJn47wmNEhxm6Mr0weDH7C2xpuIbfwv/00 76x/oXE8Idc5A6kisAVM/Jh4UposwvvD1KkFuSGgJ0b+KfQ1W+3X2TyHIKZxbn0L 5B/iIXw+SDGg/NAcVF4WGnxlx0zUnNUIvLMAAwUH/1IRrlVVO4iPlei3PjEVv7VT RCQwPfLul1CRrgXz6RlrExjCuUwJAXs789ZKfMOw4ThayWQatFAz+xJ4ESb3fXPS lWvXKJQKwviqQGoufeARh3C1paE6+yTmvPLuXHXV0RJsmW+zyuf1MwLANOlb++Be c/BcvUW8IXo6jrVRvI4lgQaPASIXuS7MFh9uBjtiK020GKGuERoks8L3pYAiscA/ EMt9KPYby79bZ/mW+TIuQons/BvVT+5GiM9mJ4hjVbkAbEEH/DvLlOn2D/niYULL Yi9uQjNZtPbast9BqwmNbO9FZBTOcRjjfgzAz54PROapizwR82FleBNcVDVqYZyI TwQYEQIADwUCTFXMpQIbDAUJA8JnAAAKCRDYNAwGQ1+hldVVAJ9MjurjfNtp4v1H +IF1MP1dU7h+FwCff+OzzB2/iffDrpk2q6KzVukYTVs= =bJNw -----END PGP PUBLIC KEY BLOCK-----
    

    Should be "fixed" in Libmacgpg (so GPGServices can use it)

  • Support
  • Mento

    Mento February 13th, 2012 @ 12:01 PM

    • State changed from “open” to “wontfix”

    I see no way to solve this problem.
    GPG doesn't recognize packets like this.

    If anyone has a possible solution, he can re-open this ticket.

  • Luke Le

    Luke Le February 13th, 2012 @ 12:44 PM

    • State changed from “wontfix” to “open”

    Breaking the format down, it's not too hard to fix such keys.

    We know there needs to be a linebreak after -----BEGIN PGP PUBLIC KEY BLOCK-----.
    The next part is the hard part, filter out the headers.
    After the headers there neeed's to be another linebreak.
    This can be tested using base64 decode and check for invalid components (split the version by spaces).
    Let's ignore for a second that the version could be some base64 encoded string.

    After we've removed the invalid components, we get to the base64 encoded key part.
    So we read the base64 till we find the ending "-----END PGP PUBLIC KEY BLOCK-----".

    After that, we build our own key using

    -----BEGIN PGP PUBLIC KEY BLOCK-----

    |base64 data|

    -----END PGP PUBLIC KEY BLOCK-----

    And we've got a valid key.

    @Mento: what problems do you see with that method, except the eventually base64 encoded comment? (but I really think, we can ignore those keys)

  • steve

    steve June 24th, 2015 @ 01:05 PM

    • Milestone set to 0.6
    • Importance changed from “” to “Low”
  • steve

    steve June 24th, 2015 @ 01:06 PM

    • Title changed from “Keys w/o line breaks” to “ Keys or messages without line breaks can not be operated”
  • Support

    Support July 3rd, 2015 @ 12:09 AM

    • State changed from “open” to “fixed”

    (from [eb388f5dcbf91e8c66a17b80fb35beea1b35db4b]) Missing commit message for ae86481.

    [#14 state:fixed assigned:mento] [#38 state:fixed assigned:mento] [#145 state:fixed assigned:mento] https://github.com/GPGTools/Libmacgpg/commit/eb388f5dcbf91e8c66a17b...

  • steve

    steve July 5th, 2015 @ 01:59 PM

    • State changed from “fixed” to “verified”

    Was able to import pub keys with missing line breaks, like the one posted in a comment in this ticket.

    Verified.

  • steve

    steve February 8th, 2016 @ 05:25 PM

    • State changed from “verified” to “released”

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Shared Ticket Bins

Referenced by

Pages