<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>8134</bug_id>
          
          <creation_ts>2015-08-10 14:12:09 +0000</creation_ts>
          <short_desc>Signing packages in the package feeds</short_desc>
          <delta_ts>2015-10-16 15:19:50 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>devtools / tool chain</component>
          <version>1.9</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>High</priority>
          <bug_severity>enhancement</bug_severity>
          <target_milestone>1.9 M3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Alexander Kanevskiy">alexander.kanevskiy</reporter>
          <assigned_to name="Markus Lehtonen">markus.lehtonen</assigned_to>
          <cc>bogdanx.a.voiculescu</cc>
    
    <cc>cathy.shen</cc>
    
    <cc>daniel.alexandrux.istrate</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>richard.purdie</cc>
          
          <qa_contact name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</qa_contact>
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>Yes (doc changes required)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>52945</commentid>
    <comment_count>0</comment_count>
    <who name="Alexander Kanevskiy">alexander.kanevskiy</who>
    <bug_when>2015-08-10 14:12:09 +0000</bug_when>
    <thetext>There is a need on signing packages produced as part of the build in the package feeds, wherever package format supports that (e.g. RPM). This would allow users to verify authenticity of packages received from those feeds.

Signing can be done either during build process or during/before package index update. Actual implementation we would need to discuss, based that different package formats have different limitations on signatures.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53058</commentid>
    <comment_count>1</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2015-08-12 21:11:12 +0000</bug_when>
    <thetext>Which packaging format are you primarily using? rpm v5 and smart?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53070</commentid>
    <comment_count>2</comment_count>
    <who name="Alexander Kanevskiy">alexander.kanevskiy</who>
    <bug_when>2015-08-13 09:01:07 +0000</bug_when>
    <thetext>Yes, at the moment it&apos;s rpm5 and smart on device.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53226</commentid>
    <comment_count>3</comment_count>
    <who name="Markus Lehtonen">markus.lehtonen</who>
    <bug_when>2015-08-19 14:37:37 +0000</bug_when>
    <thetext>Which of the following do you think would be more feasible to do:
A. Extend the existing package_rpm bbclass. Signing would possibly be enabled by defining a proper variable in conf(?)

B.Write a new bbclass for doing the package signing. Signing would be enabled by inheriting the new class e.g. in distro conf.

I&apos;m inclined to think that the second option would be better.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53329</commentid>
    <comment_count>4</comment_count>
      <attachid>2673</attachid>
    <who name="Markus Lehtonen">markus.lehtonen</who>
    <bug_when>2015-08-21 14:41:43 +0000</bug_when>
    <thetext>Created attachment 2673
POC patch for signing rpm packages</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53331</commentid>
    <comment_count>5</comment_count>
    <who name="Markus Lehtonen">markus.lehtonen</who>
    <bug_when>2015-08-21 14:44:44 +0000</bug_when>
    <thetext>I wrote a patch for generating signed RPM. Does it make any sense to you?

This currently only supports signing in the local builder. Problematic part is of course the passphrase which must be stored in a file in the local filesystem.

Also, what is lacking is the integration with smart and image generation.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53684</commentid>
    <comment_count>6</comment_count>
    <who name="Markus Lehtonen">markus.lehtonen</who>
    <bug_when>2015-09-03 13:30:11 +0000</bug_when>
    <thetext>Merged to master:
http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=752736ae9f9c8842018e45cff2f5b1d770557d86
http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=59c7c7bfcb2cf3682526656fd9eba61a022e5a0a</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53951</commentid>
    <comment_count>7</comment_count>
    <who name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</who>
    <bug_when>2015-09-11 06:34:52 +0000</bug_when>
    <thetext>ERROR: Function failed: RPM signing failed
ERROR: Task 670 (/home/bvoiculescu/yocto/poky/meta/recipes-core/glibc/glibc-locale_2.22.bb, do_package_write_rpm) failed with exit code &apos;1&apos;
NOTE: Tasks Summary: Attempted 654 tasks of which 649 didn&apos;t need to be rerun and 4 failed.
Waiting for 0 running tasks to finish:...


My setup is: 
1) in bitbake.conf

INHERIT += &quot;sign_rpm&quot;
RPM_GPG_PASSPHRASE_FILE = &quot;/home/bvoiculescu/.gnupg/secret.txt&quot;
RPM_GPG_NAME = &quot;Bogdan-Alexandru Voiculescu &lt;bogdanx.a.voiculescu@intel.com&gt;&quot;

2) 
cat /home/bvoiculescu/.gnupg/secret.txt
parola

3)
rpmsign is working:
~/yocto/poky$ rpmsign  --addsign /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/db/6.0.30-r0/deploy-rpms/i586/db-6.0.30-r0.i586.rpm
Enter pass phrase:
Pass phrase is good.
/home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/db/6.0.30-r0/deploy-rpms/i586/db-6.0.30-r0.i586.rpm:</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53963</commentid>
    <comment_count>8</comment_count>
    <who name="Markus Lehtonen">markus.lehtonen</who>
    <bug_when>2015-09-11 10:33:47 +0000</bug_when>
    <thetext>(In reply to comment #7)
&gt; ERROR: Function failed: RPM signing failed
&gt; ERROR: Task 670
&gt; (/home/bvoiculescu/yocto/poky/meta/recipes-core/glibc/glibc-locale_2.22.bb,
&gt; do_package_write_rpm) failed with exit code &apos;1&apos;
&gt; NOTE: Tasks Summary: Attempted 654 tasks of which 649 didn&apos;t need to be
&gt; rerun and 4 failed.
&gt; Waiting for 0 running tasks to finish:...

What is it that actually fails there? Does ${WORKDIR}/temp/log.do_package_write_rpm give any more insight?

 
&gt; My setup is: 
&gt; 1) in bitbake.conf
&gt; 
&gt; INHERIT += &quot;sign_rpm&quot;
&gt; RPM_GPG_PASSPHRASE_FILE = &quot;/home/bvoiculescu/.gnupg/secret.txt&quot;
&gt; RPM_GPG_NAME = &quot;Bogdan-Alexandru Voiculescu &lt;bogdanx.a.voiculescu@intel.com&gt;&quot;

The configuration looks good to me

&gt; 2) 
&gt; cat /home/bvoiculescu/.gnupg/secret.txt
&gt; parola

Looks good, too. The file should only contain one line which is the passphrase.


&gt; 3)
&gt; rpmsign is working:
&gt; ~/yocto/poky$ rpmsign  --addsign
&gt; /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/db/6.0.30-r0/
&gt; deploy-rpms/i586/db-6.0.30-r0.i586.rpm
&gt; Enter pass phrase:
&gt; Pass phrase is good.
&gt; /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/db/6.0.30-r0/
&gt; deploy-rpms/i586/db-6.0.30-r0.i586.rpm:</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53964</commentid>
    <comment_count>9</comment_count>
    <who name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</who>
    <bug_when>2015-09-11 10:39:20 +0000</bug_when>
    <thetext>nope:
bvoiculescu@vhangan-PC:~$ cat /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/linux-libc-headers/4.1-r0/temp/log.do_package_write_rpm.11256
DEBUG: Executing python function sstate_task_prefunc
DEBUG: Removing manifest: /home/bvoiculescu/yocto/poky/build/tmp/deploy/rpm/i586/linux-libc-headers-dbg-4.1-r0.i586.rpm
DEBUG: Removing manifest: /home/bvoiculescu/yocto/poky/build/tmp/deploy/rpm/i586/linux-libc-headers-dev-4.1-r0.i586.rpm
DEBUG: Removing manifest: /home/bvoiculescu/yocto/poky/build/tmp/deploy/rpm/i586/
DEBUG: Python function sstate_task_prefunc finished
DEBUG: Executing python function do_package_write_rpm
DEBUG: Executing python function read_subpackage_metadata
DEBUG: Python function read_subpackage_metadata finished
DEBUG: Executing python function do_package_rpm
DEBUG: Executing python function write_specfile
NOTE: Creating EMPTY RPM Package for linux-libc-headers-dbg
NOTE: Not creating empty RPM package for linux-libc-headers-staticdev
NOTE: Creating RPM package for linux-libc-headers-dev
NOTE: Not creating empty RPM package for linux-libc-headers-doc
NOTE: Not creating empty RPM package for linux-libc-headers-locale
NOTE: Not creating empty RPM package for linux-libc-headers
DEBUG: Python function write_specfile finished
DEBUG: PKGWRITEDIR: /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/linux-libc-headers/4.1-r0/deploy-rpms/i586
DEBUG: Executing shell function BUILDSPEC
Building target platforms: i586-poky-linux
Processing files: linux-libc-headers-dbg-4.1-r0.i586
Processing files: linux-libc-headers-dev-4.1-r0.i586
Checking for unpackaged file(s): /home/bvoiculescu/yocto/poky/build/tmp/sysroots/x86_64-linux/usr/bin/../lib/rpm/check-files /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/linux-libc-headers/4.1-r0/package
Wrote: /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/linux-libc-headers/4.1-r0/deploy-rpms/i586/linux-libc-headers-dbg-4.1-r0.i586.rpm
Wrote: /home/bvoiculescu/yocto/poky/build/tmp/work/i586-poky-linux/linux-libc-headers/4.1-r0/deploy-rpms/i586/linux-libc-headers-dev-4.1-r0.i586.rpm
DEBUG: Shell function BUILDSPEC finished
DEBUG: Executing python function sign_rpm
DEBUG: Python function sign_rpm finished
DEBUG: Python function do_package_rpm finished
DEBUG: Python function do_package_write_rpm finished
ERROR: Function failed: RPM signing failed</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54217</commentid>
    <comment_count>10</comment_count>
    <who name="Markus Lehtonen">markus.lehtonen</who>
    <bug_when>2015-09-17 15:18:38 +0000</bug_when>
    <thetext>Marking this as resolved, again.

The problem above was caused by missing &apos;gpg2&apos; binary on Ubuntu systems (they only have &apos;gpg&apos;). The problem can be circumvented by defining GPG_BIN in bitbake configuration or defining the %__gpg macro in ~/.oerpmmacros file. These settings are not required when/if this patch gets merged:
http://lists.openembedded.org/pipermail/openembedded-core/2015-September/110475.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54249</commentid>
    <comment_count>11</comment_count>
    <who name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</who>
    <bug_when>2015-09-18 07:35:25 +0000</bug_when>
    <thetext>confirmed implementation is done and rpm sign is working.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55139</commentid>
    <comment_count>12</comment_count>
    <who name="Cathy Shen">cathy.shen</who>
    <bug_when>2015-10-10 09:55:55 +0000</bug_when>
    <thetext>We trying to verify this in my project, but didn&apos;t get successful result, pls. help to check if the test steps are correct:
My steps:
1. gpg --gen-key
2. add my passwd to ~/.gnupg/secret.txt
3. edit .rpmmacros , add these contents:
%_signature gpg
%_gpgbin /usr/bin/gpg
%_gpg_name myname (test) &lt;myname@corparation.com&gt;
%_gpg_path /home/dir/.gnupg
4. git clone [my project]
5. source oe-init-build-env
6. edit conf/local.conf, add these contents(please note that if didn&apos;t add RPM_GPG_PUBKEY, bitbake will return an error):\
INHERIT += &quot;sign_rpm&quot;
RPM_GPG_PASSPHRASE_FILE = &quot;/home/dir/.gnupg/secret.txt&quot;
RPM_GPG_NAME = &quot;myname&quot;
RPM_GPG_PUBKEY = &quot;/home/dir/.gnupg/pubring.gpg&quot;
7. bitbake my-project-image
8. rpm --checksig mraa-test-1.0.0-r0.i586_nlp_32.rpm
mraa-test-1.0.0-r0.i586_nlp_32.rpm: RSA sha1 md5 NOT OK
9. rpm --resign mraa-test-1.0.0-r0.i586_nlp_32.rpm
Enter pass phrase: 
Pass phrase is good.
mraa-test-1.0.0-r0.i586_nlp_32.rpm:
warning: mraa-test-1.0.0-r0.i586_nlp_32.rpm already contains identical signature, skipping
It seems that signature has added already, but couldn&apos;t verify this key.
BTW, I tried to add sign manually, when I checksign, it will have these results:
mraa-test-1.0.0-r0.i586_nlp_32.rpm: RSA sha1 ((MD5) PGP) md5 NOT OK (MISSING KEYS: (MD5) PGP#2b1be55e)

Pls. give my some hints about the test steps. Thanks!</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55155</commentid>
    <comment_count>13</comment_count>
    <who name="Markus Lehtonen">markus.lehtonen</who>
    <bug_when>2015-10-12 07:28:01 +0000</bug_when>
    <thetext>First of all, RPM_GPG_PUBKEY must point to the public key, not the pub keyring. I.e.
$ gpg --export --armor &quot;myname (test) &lt;myname@corparation.com&gt;&quot; &gt; key.pub
and then make RPM_GPG_PUBKEY point to that file.


Worksforme. What host os do you use? It might be some incompatibility with the rpm versions of host and target systems. Try using the rpm from sysroot instead:
$ tmp-glibc/sysroots/x86_64-linux/usr/bin/rpm --import key.pug
$ tmp-glibc/sysroots/x86_64-linux/usr/bin/rpm --checksig mraa-test-1.0.0-r0.i586_nlp_32.rpm</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55399</commentid>
    <comment_count>14</comment_count>
    <who name="Daniel Istrate">daniel.alexandrux.istrate</who>
    <bug_when>2015-10-16 15:19:50 +0000</bug_when>
    <thetext>Added oe-selftest for this feature:
http://lists.openembedded.org/pipermail/openembedded-core/2015-October/111648.html</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>2673</attachid>
            <date>2015-08-21 14:41:43 +0000</date>
            <delta_ts>2015-08-21 14:41:43 +0000</delta_ts>
            <desc>POC patch for signing rpm packages</desc>
            <filename>0001-package_rpm-WIP-support-signing-of-rpm-packages.patch</filename>
            <type>text/plain</type>
            <size>4034</size>
            <attacher name="Markus Lehtonen">markus.lehtonen</attacher>
            
              <data encoding="base64">RnJvbSBmMWU0N2IwM2RhNmQ1MTAwZGFiNmI5ZmI2ZThkZTE0Y2EzOTVhNzg3IE1vbiBTZXAgMTcg
MDA6MDA6MDAgMjAwMQpGcm9tOiBNYXJrdXMgTGVodG9uZW4gPG1hcmt1cy5sZWh0b25lbkBsaW51
eC5pbnRlbC5jb20+CkRhdGU6IEZyaSwgMjEgQXVnIDIwMTUgMTc6MjE6NTcgKzAzMDAKU3ViamVj
dDogW1BBVENIXSBwYWNrYWdlX3JwbTogV0lQOiBzdXBwb3J0IHNpZ25pbmcgb2YgcnBtIHBhY2th
Z2VzCgpUaGlzIHBhdGNoIGFkZHMgYSBuZXcgYmJjbGFzcyBmb3IgZ2VuZXJhdGluZyBzaWduZWQg
cnBtIHBhY2thZ2VzLgoKSW4gb3JkZXIgdG8gZW5hYmxlIHRoZSBmZWF0dXJlIHlvdSBuZWVkIHRv
CjEuICdJTkhFUklUICs9ICIgc2lnbl9ycG0iJyBpbiBiaXRiYWtlIGNvbmZpZyAoZS5nLiBsb2Nh
bCBvcgogICBkaXN0cm8pCjIuIENyZWF0ZSBhIGZpbGUgdGhhdCBjb250YWlucyB0aGUgcGFzc3Bo
cmFzZSB0byB5b3VyIGdwZyBzZWNyZXQga2V5CjMuICdSUE1fR1BHX1BBU1NQSFJBU0VfRklMRSA9
ICI8cGF0aF90b19maWxlPiIgaW4gYml0YmFrZSBjb25maWcsCiAgIHBvaW50aW5nIHRvIHRoZSBw
YXNzcGhyYXNlIGZpbGUgY3JlYXRlZCBpbiAyLgo0LiBEZWZpbmUgR1BHIGtleSBuYW1lIHRvIHVz
ZSBieSBlaXRoZXIgZGVmaW5pbmcKICAgJ1JQTV9HUEdfTkFNRSA9ICI8a2V5X2l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3BnX3Bh
c3NwaHJhc2UsIHJwbV9ncGdfbmFtZSkgIT0gMDoKKyAgICAgICAgcmFpc2UgYmIuYnVpbGQuRnVu
Y0ZhaWxlZCgiUlBNIHNpZ25pbmcgZmFpbGVkIikKK30KLS0gCjIuMS40Cgo=
</data>

          </attachment>
      

    </bug>

</bugzilla>