##// END OF EJS Templates
tests: don't save host fingerprints in hgrc...
Gregory Szorc -
r29263:817ee3cf default
parent child Browse files
Show More
@@ -282,12 +282,8 b' Test server cert which no longer is vali'
282
282
283 Fingerprints
283 Fingerprints
284
284
285 $ echo "[hostfingerprints]" >> copy-pull/.hg/hgrc
286 $ echo "localhost = 91:4f:1a:ff:87:24:9c:09:b6:85:9b:88:b1:90:6d:30:75:64:91:ca" >> copy-pull/.hg/hgrc
287 $ echo "127.0.0.1 = 914f1aff87249c09b6859b88b1906d30756491ca" >> copy-pull/.hg/hgrc
288
289 - works without cacerts
285 - works without cacerts
290 $ hg -R copy-pull id https://localhost:$HGPORT/ --insecure
286 $ hg -R copy-pull id https://localhost:$HGPORT/ --insecure --config hostfingerprints.localhost=91:4f:1a:ff:87:24:9c:09:b6:85:9b:88:b1:90:6d:30:75:64:91:ca
291 5fed3813f7f5
287 5fed3813f7f5
292
288
293 - multiple fingerprints specified and first matches
289 - multiple fingerprints specified and first matches
@@ -306,14 +302,14 b' Fingerprints'
306 [255]
302 [255]
307
303
308 - fails when cert doesn't match hostname (port is ignored)
304 - fails when cert doesn't match hostname (port is ignored)
309 $ hg -R copy-pull id https://localhost:$HGPORT1/
305 $ hg -R copy-pull id https://localhost:$HGPORT1/ --config hostfingerprints.localhost=914f1aff87249c09b6859b88b1906d30756491ca
310 abort: certificate for localhost has unexpected fingerprint 28:ff:71:bf:65:31:14:23:ad:62:92:b4:0e:31:99:18:fc:83:e3:9b
306 abort: certificate for localhost has unexpected fingerprint 28:ff:71:bf:65:31:14:23:ad:62:92:b4:0e:31:99:18:fc:83:e3:9b
311 (check hostfingerprint configuration)
307 (check hostfingerprint configuration)
312 [255]
308 [255]
313
309
314
310
315 - ignores that certificate doesn't match hostname
311 - ignores that certificate doesn't match hostname
316 $ hg -R copy-pull id https://127.0.0.1:$HGPORT/
312 $ hg -R copy-pull id https://127.0.0.1:$HGPORT/ --config hostfingerprints.127.0.0.1=914f1aff87249c09b6859b88b1906d30756491ca
317 5fed3813f7f5
313 5fed3813f7f5
318
314
319 HGPORT1 is reused below for tinyproxy tests. Kill that server.
315 HGPORT1 is reused below for tinyproxy tests. Kill that server.
@@ -344,7 +340,7 b' Test https with cacert and fingerprint t'
344 pulling from https://localhost:$HGPORT/
340 pulling from https://localhost:$HGPORT/
345 searching for changes
341 searching for changes
346 no changes found
342 no changes found
347 $ http_proxy=http://localhost:$HGPORT1/ hg -R copy-pull pull https://127.0.0.1:$HGPORT/
343 $ http_proxy=http://localhost:$HGPORT1/ hg -R copy-pull pull https://127.0.0.1:$HGPORT/ --config hostfingerprints.127.0.0.1=914f1aff87249c09b6859b88b1906d30756491ca
348 pulling from https://127.0.0.1:$HGPORT/
344 pulling from https://127.0.0.1:$HGPORT/
349 searching for changes
345 searching for changes
350 no changes found
346 no changes found
General Comments 0
You need to be logged in to leave comments. Login now