Skip to content

Commit 7c7cd7f

Browse files
committed
Fix registrar client issue after rebasing
Signed-off-by: Sergio Arroutbi <sarroutb@redhat.com>
1 parent 982a483 commit 7c7cd7f

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

keylime/src/https_client.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ mod tests {
8585
key: key_path.to_string_lossy().to_string(),
8686
insecure: Some(false),
8787
timeout: 5000,
88+
accept_invalid_hostnames: true,
8889
};
8990

9091
let result = get_https_client(&args);
@@ -108,6 +109,7 @@ mod tests {
108109
key: key_path.to_string_lossy().to_string(),
109110
insecure: Some(true),
110111
timeout: 5000,
112+
accept_invalid_hostnames: true,
111113
};
112114

113115
let result = get_https_client(&args);
@@ -135,6 +137,7 @@ mod tests {
135137
key: tmpdir.path().join("key.pem").to_string_lossy().to_string(),
136138
insecure: Some(false),
137139
timeout: 5000,
140+
accept_invalid_hostnames: true,
138141
};
139142

140143
let result = get_https_client(&args);
@@ -165,6 +168,7 @@ mod tests {
165168
key: tmpdir.path().join("key.pem").to_string_lossy().to_string(),
166169
insecure: Some(false),
167170
timeout: 5000,
171+
accept_invalid_hostnames: true,
168172
};
169173

170174
let result = get_https_client(&args);
@@ -198,6 +202,7 @@ mod tests {
198202
.to_string(),
199203
insecure: Some(false),
200204
timeout: 5000,
205+
accept_invalid_hostnames: true,
201206
};
202207

203208
let result = get_https_client(&args);
@@ -232,6 +237,7 @@ mod tests {
232237
key: key_path.to_string_lossy().to_string(),
233238
insecure: Some(false),
234239
timeout: 5000,
240+
accept_invalid_hostnames: true,
235241
};
236242

237243
let result = get_https_client(&args);
@@ -273,6 +279,7 @@ mod tests {
273279
key: invalid_key_path.to_string_lossy().to_string(),
274280
insecure: Some(false),
275281
timeout: 5000,
282+
accept_invalid_hostnames: true,
276283
};
277284

278285
let result = get_https_client(&args);
@@ -300,6 +307,7 @@ mod tests {
300307
key: key_path.to_string_lossy().to_string(),
301308
insecure: Some(false),
302309
timeout,
310+
accept_invalid_hostnames: true,
303311
};
304312

305313
let result = get_https_client(&args);
@@ -326,6 +334,7 @@ mod tests {
326334
key: key_path.to_string_lossy().to_string(),
327335
insecure: None,
328336
timeout: 5000,
337+
accept_invalid_hostnames: true,
329338
};
330339

331340
let result = get_https_client(&args);
@@ -343,6 +352,7 @@ mod tests {
343352
key: "key.pem".to_string(),
344353
insecure: Some(false),
345354
timeout: 5000,
355+
accept_invalid_hostnames: true,
346356
};
347357

348358
let result = get_https_client(&args);

keylime/src/registrar_client.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,7 @@ impl RegistrarClientBuilder {
257257
key: self.key.clone().unwrap_or_default(),
258258
insecure: self.insecure,
259259
timeout: self.timeout.unwrap_or(5000),
260+
accept_invalid_hostnames: false,
260261
};
261262
https_client::get_https_client(&args)?
262263
} else {

0 commit comments

Comments
 (0)