]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/options.py
Add support for SSL client certificate authentication (#3435)
[yt-dlp.git] / yt_dlp / options.py
index 944147871d89794e4485a37e9feadfa0204ae7cc..60f86657059ebd594e4d0b183adbdb4ca5fdff30 100644 (file)
@@ -571,6 +571,19 @@ def _dict_from_options_callback(
         '--ap-list-mso',
         action='store_true', dest='ap_list_mso', default=False,
         help='List all supported multiple-system operators')
+    authentication.add_option(
+        '--client-certificate',
+        dest='client_certificate', metavar='CERTFILE',
+        help='Path to client certificate file in PEM format. May include the private key')
+    authentication.add_option(
+        '--client-certificate-key',
+        dest='client_certificate_key', metavar='KEYFILE',
+        help='Path to private key file for client certificate')
+    authentication.add_option(
+        '--client-certificate-password',
+        dest='client_certificate_password', metavar='PASSWORD',
+        help='Password for client certificate private key, if encrypted. '
+             'If not provided and the key is encrypted, yt-dlp will ask interactively')
 
     video_format = optparse.OptionGroup(parser, 'Video Format Options')
     video_format.add_option(