Hello community, here is the log from the commit of package rubygem-gpgme for openSUSE:Factory checked in at 2020-03-07 21:38:14 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/rubygem-gpgme (Old) and /work/SRC/openSUSE:Factory/.rubygem-gpgme.new.26092 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "rubygem-gpgme" Sat Mar 7 21:38:14 2020 rev:10 rq:773766 version:2.0.19 Changes: -------- --- /work/SRC/openSUSE:Factory/rubygem-gpgme/rubygem-gpgme.changes 2019-01-21 10:25:49.045720036 +0100 +++ /work/SRC/openSUSE:Factory/.rubygem-gpgme.new.26092/rubygem-gpgme.changes 2020-03-07 21:38:20.136276081 +0100 @@ -1,0 +2,6 @@ +Mon Feb 10 14:46:26 UTC 2020 - Stephan Kulow <co...@suse.com> + +- updated to version 2.0.19 + no changelog found + +------------------------------------------------------------------- Old: ---- gpgme-2.0.18.gem New: ---- gpgme-2.0.19.gem ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ rubygem-gpgme.spec ++++++ --- /var/tmp/diff_new_pack.nizd0l/_old 2020-03-07 21:38:21.772277186 +0100 +++ /var/tmp/diff_new_pack.nizd0l/_new 2020-03-07 21:38:21.772277186 +0100 @@ -1,7 +1,7 @@ # # spec file for package rubygem-gpgme # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -24,7 +24,7 @@ # Name: rubygem-gpgme -Version: 2.0.18 +Version: 2.0.19 Release: 0 %define mod_name gpgme %define mod_full_name %{mod_name}-%{version} @@ -37,7 +37,7 @@ BuildRequires: %{rubydevel} BuildRequires: %{rubygem gem2rpm} BuildRequires: ruby-macros >= 5 -Url: http://github.com/ueno/ruby-gpgme +URL: http://github.com/ueno/ruby-gpgme Source: https://rubygems.org/gems/%{mod_full_name}.gem Source1: rubygem-gpgme-rpmlintrc Source2: gem2rpm.yml ++++++ gpgme-2.0.18.gem -> gpgme-2.0.19.gem ++++++ Binary files old/checksums.yaml.gz and new/checksums.yaml.gz differ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/lib/gpgme/ctx.rb new/lib/gpgme/ctx.rb --- old/lib/gpgme/ctx.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/lib/gpgme/ctx.rb 2019-10-03 14:04:53.000000000 +0200 @@ -370,8 +370,8 @@ # # If passed, the key will be exported to +keydata+, which must be # a {GPGME::Data} object. - def export_keys(recipients, keydata = Data.new) - err = GPGME::gpgme_op_export(self, recipients, 0, keydata) + def export_keys(recipients, keydata = Data.new, mode=0) + err = GPGME::gpgme_op_export(self, recipients, mode, keydata) exc = GPGME::error_to_exception(err) raise exc if exc keydata diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/lib/gpgme/data.rb new/lib/gpgme/data.rb --- old/lib/gpgme/data.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/lib/gpgme/data.rb 2019-10-03 14:04:53.000000000 +0200 @@ -165,8 +165,16 @@ end ## - # Sets the encoding for this buffer. Accepts only values in one of the - # DATA_ENCODING_* constants. + # Sets the encoding for this buffer. Accepts only integer values 0 to 7: + # + # 0 = GPGME_DATA_ENCODING_NONE (Not specified) + # 1 = GPGME_DATA_ENCODING_BINARY + # 2 = GPGME_DATA_ENCODING_BASE64 + # 3 = GPGME_DATA_ENCODING_ARMOR (Either PEM or OpenPGP Armor) + # 4 = GPGME_DATA_ENCODING_URL (LF delimited URL list) + # 5 = GPGME_DATA_ENCODING_URLESC (Ditto, but percent escaped) + # 6 = GPGME_DATA_ENCODING_URL0 (Nul delimited URL list) + # 7 = GPGME_DATA_ENCODING_MIME (Data is a MIME part) # # @raise [GPGME::Error::InvalidValue] if the value isn't accepted. def encoding=(encoding) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/lib/gpgme/key.rb new/lib/gpgme/key.rb --- old/lib/gpgme/key.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/lib/gpgme/key.rb 2019-10-03 14:04:53.000000000 +0200 @@ -81,6 +81,7 @@ # @param [Hash] options # * +:output+ specify where to write the key to. It will be converted to # a {GPGME::Data}, so it could be a file, for example. + # * +:minimal+ set to true to let the export mode be 'minimal'. # * Any other option accepted by {GPGME::Ctx.new} # # @return [GPGME::Data] the exported key. @@ -94,9 +95,14 @@ # def export(pattern, options = {}) output = Data.new(options[:output]) + if options.delete(:minimal) == true + export_mode = 4 + else + export_mode = 0 + end GPGME::Ctx.new(options) do |ctx| - ctx.export_keys(pattern, output) + ctx.export_keys(pattern, output, export_mode) end output.seek(0) @@ -122,6 +128,12 @@ ctx.import_result end end + + # Checks if a key is valid + def valid?(key) + GPGME::Key.import(key).considered == 1 + end + end ## diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/lib/gpgme/version.rb new/lib/gpgme/version.rb --- old/lib/gpgme/version.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/lib/gpgme/version.rb 2019-10-03 14:04:53.000000000 +0200 @@ -1,4 +1,4 @@ module GPGME # The version of GPGME ruby binding you are using - VERSION = "2.0.18" + VERSION = "2.0.19" end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/metadata new/metadata --- old/metadata 2018-11-22 14:05:33.000000000 +0100 +++ new/metadata 2019-10-03 14:04:53.000000000 +0200 @@ -1,7 +1,7 @@ --- !ruby/object:Gem::Specification name: gpgme version: !ruby/object:Gem::Version - version: 2.0.18 + version: 2.0.19 platform: ruby authors: - Daiki Ueno @@ -141,9 +141,11 @@ - test/ctx_test.rb - test/data_test.rb - test/files/testkey_pub.gpg +- test/files/testkey_pub_invalid.gpg - test/files/testkey_sec.gpg - test/gpgme_test.rb - test/key_test.rb +- test/pinentry - test/signature_test.rb - test/sub_key_test.rb - test/support/resources.rb @@ -169,7 +171,7 @@ version: '0' requirements: [] rubyforge_project: ruby-gpgme -rubygems_version: 2.7.3 +rubygems_version: 2.6.14.3 signing_key: specification_version: 4 summary: Ruby binding of GPGME. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/crypto_test.rb new/test/crypto_test.rb --- old/test/crypto_test.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/test/crypto_test.rb 2019-10-03 14:04:54.000000000 +0200 @@ -128,6 +128,11 @@ end describe "symmetric encryption/decryption" do + before do + info = GPGME::Engine.info.first + skip if /\A2\.[01]|\A1\./ === info.version + end + it "requires a password to encrypt" do assert_raises GPGME::Error::BadPassphrase do GPGME::Crypto.new.encrypt TEXT[:plain], :symmetric => true diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/ctx_test.rb new/test/ctx_test.rb --- old/test/ctx_test.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/test/ctx_test.rb 2019-10-03 14:04:54.000000000 +0200 @@ -27,6 +27,11 @@ end describe :new do + before do + info = GPGME::Engine.info.first + skip if /\A2\.[01]|\A1\./ === info.version + end + # We consider :armor, :protocol, :textmode and :keylist_mode as tested # with the other tests of this file. Here we test the rest @@ -398,6 +403,26 @@ import_keys # If the test fails for some reason, it won't break others. end + + it "exports a minimal key if given the mode" do + remove_all_keys + GPGME::Key.import(KEY_WITH_SIGNATURE[:public]) + key = GPGME::Key.find(KEY_WITH_SIGNATURE[:sha]).first + output_normal = GPGME::Data.new + output_minimal = GPGME::Data.new + ctx = GPGME::Ctx.new + + ctx.export_keys(key.sha, output_normal) + ctx.export_keys(key.sha, output_minimal, 4) + + output_normal.seek(0) + output_minimal.seek(0) + + assert_equal output_normal.read.size, 849 + assert_equal output_minimal.read.size, 668 + + import_keys # If the test fails for some reason, it won't break others. + end it "exports only one key" do original_keys = GPGME::Key.find(:public) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/files/testkey_pub_invalid.gpg new/test/files/testkey_pub_invalid.gpg --- old/test/files/testkey_pub_invalid.gpg 1970-01-01 01:00:00.000000000 +0100 +++ new/test/files/testkey_pub_invalid.gpg 2019-10-03 14:04:54.000000000 +0200 @@ -0,0 +1,52 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- +Version: GnuPG v1.4.11 (Darwin) + +QmSuBE1tOWYRDAC0MiL/mUsW1I18H9TZzurEXM0HMxFcQ5LlGm+0Zk+tSI/AVk4G +mZRppURYAFPyOQLOT6sm4vPXJ29uRJ8WSHtryg1HqPvIPauZVB9tSW10K7gmpdSd +pty2/QGa8dNEnlMIJN8Kti0qaU72jfBH1r3mdpZ+P4KNFIKgYTbavzJ3GOtrypBz +K52nH/baQM3wBQ31JKsM8qJy3Vf5jmc1vD3bim3QMarjKRPeE3e6T3iwrtc9MG8N +ayD/taUUeunkEIMO6B1iRykSF+7i8RlOVv9ubJEi92VfMGw5QEnmjKJf/v/GRsFt +82Y7zQ7x4MmZgUITubePKRrYnF1BSBAwk4Mn6r8lXjmEN+xNQlR7T69WiSbEi3NM +dcSP+kBNZIqY20szsjb+0MrA1A9/H7cS7ITZ3eQmCw5b77lzA2n588D6cw/EBgvf +jiepPhh5az/La1OFVeSKXUJeLrWbJQyxZ312INWe0IctmMy8Y8jmdtsZSQ7oKbDR +zF1+Rx9DCYD+vIsBAPp4UUg+SMV4KKgco36G69hXOY0smR8MUD0VnwUNyWE9C/9k +tzK6s6z7MDd1uruGemxPRCHnxs520IFPcgStTNpc6KpmncZEL1/GWZeXYcs+Syn/ +c0GhB4wkvvXNP9zKEmXRE+qVX2ogxcuC4Ckfor9qvYcCc2ANRn6YhTlebftLf5F/ +G/fg1oLE0OU7nDha5773LptXomchK11yeDXlMWfS5LOV/KlqNoLJrOlcvvQmnVhT +tIBNuRYAF86cfI2hegRvshG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0VXwY7BH81NRpwAYp/eeSGP1vxBCdqVAHMc4o3TUoWHAEA +vioivJ/Qvnb7nlHwagl5rLNXhiz/H71jmFS9x0x7FLg= +=T/Ce +-----END PGP PUBLIC KEY BLOCK----- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/key_test.rb new/test/key_test.rb --- old/test/key_test.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/test/key_test.rb 2019-10-03 14:04:54.000000000 +0200 @@ -66,13 +66,13 @@ # Testing the lazy way with expectations. I think tests in # the Ctx class are enough. it "exports any key that matches the pattern" do - GPGME::Ctx.any_instance.expects(:export_keys).with("", anything) + GPGME::Ctx.any_instance.expects(:export_keys).with("", anything, 0) GPGME::Key.export("") end it "exports any key that matches the pattern, can specify output" do data = GPGME::Data.new - GPGME::Ctx.any_instance.expects(:export_keys).with("wadus", data) + GPGME::Ctx.any_instance.expects(:export_keys).with("wadus", data, 0) ret = GPGME::Key.export("wadus", :output => data) assert_equal data, ret end @@ -81,6 +81,11 @@ GPGME::Ctx.expects(:new).with(:armor => true).yields(mock(:export_keys => true)) GPGME::Key.export("wadus", :armor => true) end + + it "can export a minimal key" do + GPGME::Ctx.any_instance.expects(:export_keys).with("wadus", anything, 4) + GPGME::Key.export("wadus", :minimal => true) + end end describe "#export" do @@ -180,7 +185,7 @@ with_key EXPIRED_KEY do key = GPGME::Key.find(:secret, EXPIRED_KEY[:sha]).first - assert key.expired + assert key.expired if key end end @@ -199,6 +204,18 @@ end end + describe :valid? do + it "returns true on a valid key" do + valid_key = File.read("test/files/testkey_pub.gpg") + assert GPGME::Key.valid?(valid_key) + end + + it "returns false on an invalid key" do + invalid_key = File.read("test/files/testkey_pub_invalid.gpg") + assert !GPGME::Key.valid?(invalid_key) + end + end + describe :to_s do it "can be coerced into a String" do key = GPGME::Key.find(:secret).first @@ -206,4 +223,3 @@ end end end - diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/pinentry new/test/pinentry --- old/test/pinentry 1970-01-01 01:00:00.000000000 +0100 +++ new/test/pinentry 2019-10-03 14:04:54.000000000 +0200 @@ -0,0 +1,22 @@ +#! /bin/bash +# Dummy pinentry +# +# Copyright 2008 g10 Code GmbH +# +# This file is free software; as a special exception the author gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. +# +# This file is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the +# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR +# PURPOSE. + +echo OK Your orders please + +while read cmd; do + case $cmd in + GETPIN) echo D gpgme; echo OK;; + *) echo OK;; + esac +done diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/sub_key_test.rb new/test/sub_key_test.rb --- old/test/sub_key_test.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/test/sub_key_test.rb 2019-10-03 14:04:54.000000000 +0200 @@ -26,8 +26,11 @@ refute subkey.expired with_key EXPIRED_KEY do - subkey = GPGME::Key.find(:secret, EXPIRED_KEY[:sha]).first.primary_subkey - assert subkey.expired + key = GPGME::Key.find(:secret, EXPIRED_KEY[:sha]).first + if key + subkey = key.primary_subkey + assert subkey.expired + end end end diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/support/resources.rb new/test/support/resources.rb --- old/test/support/resources.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/test/support/resources.rb 2019-10-03 14:04:54.000000000 +0200 @@ -386,6 +386,31 @@ -----END PGP PRIVATE KEY BLOCK----- RUBY +key_with_signature = <<-RUBY +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mI0ETbL4sAEEANBs/WsOxRCLdsW1h8LKGT6eJpAs6omGV/G7TJnMsk92BUIub3oZ +9oRC1L0l4EKB6o8/vULziT815dbbVxwQIOyDXEqP4sokRxjSNNkpPb+RuIjdmP6e +SJ2NxCxV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RUBY -----BEGIN PGP MESSAGE----- Version: GnuPG v1.4.11 (Darwin) @@ -506,6 +531,11 @@ :secret => expired_key_secret } +KEY_WITH_SIGNATURE = { + :sha => 'te...@example.com', + :public => key_with_signature +} + TEXT = { :plain => "Hi there", :encrypted => encrypted_text.chomp, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/test/test_helper.rb new/test/test_helper.rb --- old/test/test_helper.rb 2018-11-22 14:05:33.000000000 +0100 +++ new/test/test_helper.rb 2019-10-03 14:04:54.000000000 +0200 @@ -99,11 +99,17 @@ # We use a different home directory for the keys to not disturb current # installation require 'tmpdir' + require 'pathname' if DIRS.empty? dir = Dir.mktmpdir GPGME::Engine.home_dir = dir DIRS.push(dir) + pinentry = Pathname.new(__FILE__).dirname + 'pinentry' + gpg_agent_conf = Pathname.new(dir) + 'gpg-agent.conf' + gpg_agent_conf.open('w+') {|io| + io.write("pinentry-program #{pinentry}\n") + } remove_all_keys import_keys end