search for: verify_and_remove_signature

Displaying 14 results from an estimated 14 matches for "verify_and_remove_signature".

2015 Jul 28
0
[PATCH 09/10] builder: add Sigchecker.verify_and_remove_signature
...insertions(+), 2 deletions(-) diff --git a/builder/sigchecker.ml b/builder/sigchecker.ml index 86e60ac..42d55cd 100644 --- a/builder/sigchecker.ml +++ b/builder/sigchecker.ml @@ -182,12 +182,30 @@ and verify_detached t filename sigfile = do_verify t args ) -and do_verify t args = +and verify_and_remove_signature t filename = + if t.check_signature then ( + (* Copy the input file as temporary file with the .asc extension, + * so gpg recognises that format. *) + let asc_file = Filename.temp_file "vbfile" ".asc" in + unlink_on_exit asc_file; + let cmd = sprintf "cp %s...
2016 Oct 24
0
[PATCH 2/2] builder: consolidate handling of temporary files/dirs
...eck_signature = fingerprint = fingerprint; subkeys_fingerprints = subkeys; check_signature = check_signature; - gpghome = tmpdir; + gpghome = gpgtmpdir; + tmpdir = tmpdir; } (* Compare two strings of hex digits ignoring whitespace and case. *) @@ -179,12 +178,10 @@ and verify_and_remove_signature t filename = if t.check_signature then ( (* Copy the input file as temporary file with the .asc extension, * so gpg recognises that format. *) - let asc_file = Filename.temp_file "vbfile" ".asc" in - unlink_on_exit asc_file; + let asc_file = Filename.temp_...
2016 Oct 25
0
[PATCH v2 2/2] builder: consolidate handling of temporary files/dirs
...eck_signature = fingerprint = fingerprint; subkeys_fingerprints = subkeys; check_signature = check_signature; - gpghome = tmpdir; + gpghome = gpgtmpdir; + tmpdir = tmpdir; } (* Compare two strings of hex digits ignoring whitespace and case. *) @@ -179,12 +178,10 @@ and verify_and_remove_signature t filename = if t.check_signature then ( (* Copy the input file as temporary file with the .asc extension, * so gpg recognises that format. *) - let asc_file = Filename.temp_file "vbfile" ".asc" in - unlink_on_exit asc_file; + let asc_file = Filename.temp_...
2016 Oct 25
2
[PATCH v2 1/2] mllib: curl: add optional tmpdir parameter
Add a new optional parameter for the Curl ADT, so temporary files can be created in a specified directory (which is supposed to be temporary, and disposed only when the application quits). --- mllib/curl.ml | 10 ++++++---- mllib/curl.mli | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/mllib/curl.ml b/mllib/curl.ml index 376406e..baa75ec 100644 --- a/mllib/curl.ml +++
2016 Oct 24
2
[PATCH 1/2] mllib: curl: add optional tmpdir parameter
Add a new optional parameter for the Curl ADT, so temporary files can be created in a specified directory (which is supposed to be temporary, and disposed only when the application quits). --- mllib/curl.ml | 16 +++++++++++----- mllib/curl.mli | 2 +- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/mllib/curl.ml b/mllib/curl.ml index 376406e..7d07125 100644 --- a/mllib/curl.ml
2015 Jul 28
19
[PATCH 00/10] RFC: builder: first support for Simple Streams metadata
...ms module builder: add SHA256 support in Checksums builder: internally use a list of checksums for indexes builder: allow signatures from subkeys builder: split Index_parser.index in an own module fix -- add Index builder: expose Sigchecker.verifying_signatures builder: add Sigchecker.verify_and_remove_signature builder: support Simple Streams v1.0 as index metadata builder/Makefile.am | 17 +++- builder/builder.ml | 45 +++++---- builder/checksums.ml | 58 +++++++++++ builder/checksums.mli | 33 +++++++ builder/index.ml | 117 ++++++...
2015 Aug 12
0
[PATCH 2/2] builder: support Simple Streams v1.0 as index metadata
...n + + let download_and_parse uri = + let tmpfile, delete_tmpfile = Downloader.download downloader ~proxy uri in + if delete_tmpfile then + unlink_on_exit tmpfile; + let file = + if Sigchecker.verifying_signatures sigchecker then ( + let tmpunsigned = + Sigchecker.verify_and_remove_signature sigchecker tmpfile in + match tmpunsigned with + | None -> assert false (* only when not verifying signatures *) + | Some f -> f + ) else + tmpfile in + yajl_tree_parse (read_whole_file file) in + + let downloads = + let uri_index = + if Sigchecker...
2016 May 23
0
[PATCH 5/5] mllib: add a new run_command helper
...error (f_"cp (download) command failed copying '%s'") path; | _ as protocol -> (* Any other protocol. *) diff --git a/builder/sigchecker.ml b/builder/sigchecker.ml index d30baf5..5289d30 100644 --- a/builder/sigchecker.ml +++ b/builder/sigchecker.ml @@ -183,8 +183,8 @@ and verify_and_remove_signature t filename = * so gpg recognises that format. *) let asc_file = Filename.temp_file "vbfile" ".asc" in unlink_on_exit asc_file; - let cmd = sprintf "cp %s %s" (quote filename) (quote asc_file) in - if shell_command cmd <> 0 then exit 1; +...
2016 May 23
7
[PATCH 1/5] mllib: make external_command echo the command executed
Add an optional parameter to disable this behaviour, so the Curl module in v2v won't print user-sensible data (like passwords). --- builder/checksums.ml | 1 - builder/downloader.ml | 1 - builder/sigchecker.ml | 1 - mllib/common_utils.ml | 4 +++- mllib/common_utils.mli | 7 +++++-- v2v/curl.ml | 2 +- 6 files changed, 9 insertions(+), 7 deletions(-) diff --git
2015 Sep 07
0
[PATCH 4/4] builder: support Simple Streams v1.0 as index metadata
...n + + let download_and_parse uri = + let tmpfile, delete_tmpfile = Downloader.download downloader ~proxy uri in + if delete_tmpfile then + unlink_on_exit tmpfile; + let file = + if Sigchecker.verifying_signatures sigchecker then ( + let tmpunsigned = + Sigchecker.verify_and_remove_signature sigchecker tmpfile in + match tmpunsigned with + | None -> assert false (* only when not verifying signatures *) + | Some f -> f + ) else + tmpfile in + yajl_tree_parse (read_whole_file file) in + + let downloads = + let uri_index = + if Sigchecker...
2015 Aug 12
4
[PATCH 0/2 v2] RFC: builder: support for Simple Streams metadata
Hi, this series adds a basic support for Simple Streams v1.0 metadata files. This makes it possible to create a repository .conf files with [cirros] uri=http://download.cirros-cloud.net format=simplestreams to read the latest version of each CirrOS image. TODO items: - check the pasted metadata: listing and creating images works, so most of the current metadata is correct - possibly wait
2016 May 22
0
[PATCH 2/2] ocaml tools: Use a common debug function.
...verbose () then printf "%s\n%!" cmd; + debug "%s" cmd; let r = Sys.command cmd in if r <> 0 then error (f_"could not export public key\nUse the '-v' option and look for earlier error messages."); @@ -189,7 +189,7 @@ and verify_and_remove_signature t filename = let asc_file = Filename.temp_file "vbfile" ".asc" in unlink_on_exit asc_file; let cmd = sprintf "cp %s %s" (quote filename) (quote asc_file) in - if verbose () then printf "%s\n%!" cmd; + debug "%s" cmd; if Sys...
2016 May 22
4
ocaml tools: Use a common debug function.
Add a Common_utils.debug function for printing messages only when in verbose mode. Rich.
2015 Sep 07
5
[PATCH 0/4 v3] builder: support for Simple Streams metadata
Hi, this series adds a basic support for Simple Streams v1.0 metadata files. This makes it possible to create a repository .conf files with [cirros] uri=http://download.cirros-cloud.net format=simplestreams to read the latest version of each CirrOS image. Thanks, Pino Toscano (4): builder: add non-int revisions builder: add simple libyajl binding build: expose HAVE_YAJL to automake