Skip to content

Commit 5e00eba

Browse files
author
Phus Lu
committed
CA-208537: vdi-copy between local SRs proposes unwanted ciphers
Enable TLSv1.2 capability for sparse_dd. Signed-off-by: Phus Lu <phus.lu@citrix.com>
1 parent f273ab5 commit 5e00eba

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

ocaml/xapi/sparse_dd_wrapper.ml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,15 @@ let dd_internal progress_cb base prezeroed infile outfile size =
7070
"-machine";
7171
"-src"; infile;
7272
"-dest"; outfile;
73-
"-size"; Int64.to_string size
74-
] @ (if prezeroed then [ "-prezeroed" ] else []
73+
"-size"; Int64.to_string size;
74+
"-good-ciphersuites"; (match !Xapi_globs.ciphersuites_good_outbound with
75+
| Some s -> s
76+
| None -> raise (Api_errors.Server_error
77+
(Api_errors.internal_error,["Vdi_copy found no good ciphersuites in Xapi_globs."]))
78+
);
79+
"-legacy-ciphersuites"; !Xapi_globs.ciphersuites_legacy_outbound
80+
] @ (if Stunnel.is_legacy_protocol_and_ciphersuites_allowed () then [ "-ssl-legacy" ] else []
81+
) @ (if prezeroed then [ "-prezeroed" ] else []
7582
) @ (Opt.default [] (Opt.map (fun x -> [ "-base"; x ]) base)) in
7683
debug "%s %s" sparse_dd_path (String.concat " " args);
7784
let pid = Forkhelpers.safe_close_and_exec None (Some pipe_write) (Some log_fd) []

0 commit comments

Comments
 (0)