Set the full path to the certificate,keyfile, etc. for the test.
(file)
| 26 | |
| 27 | |
| 28 | def _testpath(file): |
| 29 | """ Set the full path to the certificate,keyfile, etc. for the test. |
| 30 | """ |
| 31 | if os.name == "nt": |
| 32 | if file.find("private-key") != -1: |
| 33 | # The private key is not in a separate store |
| 34 | return None |
| 35 | # Substitute pkcs#12 equivalent for the CA/key store |
| 36 | if file.endswith(".pem"): |
| 37 | file = file[:-4] + ".p12" |
| 38 | return os.path.join(os.path.dirname(__file__), |
| 39 | "ssl_db/%s" % file) |
| 40 | |
| 41 | |
| 42 | class SslTest(common.Test): |