apt_key: fix spurious failure to import a subkey (#4366)
Importing a (sign only) subkey with apt_key module always fails, however the actual keyring gets created and contains the correct keys. Apparently the all_keys function skips the subkeys, hence the problem. Fixes #4365
This commit is contained in:
parent
fc87dd9650
commit
8d4fe2a767
1 changed files with 1 additions and 1 deletions
|
@ -132,7 +132,7 @@ def all_keys(module, keyring, short_format):
|
||||||
results = []
|
results = []
|
||||||
lines = out.split('\n')
|
lines = out.split('\n')
|
||||||
for line in lines:
|
for line in lines:
|
||||||
if line.startswith("pub"):
|
if line.startswith("pub") or line.startswith("sub"):
|
||||||
tokens = line.split()
|
tokens = line.split()
|
||||||
code = tokens[1]
|
code = tokens[1]
|
||||||
(len_type, real_code) = code.split("/")
|
(len_type, real_code) = code.split("/")
|
||||||
|
|
Loading…
Add table
Reference in a new issue