summaryrefslogtreecommitdiff
path: root/keystoneclient/shell.py
diff options
context:
space:
mode:
authorSascha Peilicke <saschpe@suse.de>2012-07-09 17:07:41 +0200
committerSascha Peilicke <saschpe@suse.de>2012-07-20 10:22:03 +0200
commitdec8f77c9233f195999b8db9adbd4f026834fd42 (patch)
treec8781c661b86f4eb67b9f562e8285819abb7ce4c /keystoneclient/shell.py
parente77234bd3e9f49de509bd1ff776966e58be79904 (diff)
downloadpython-keystoneclient-0.1.2.tar.gz
Add '--insecure' commandline argument0.1.2
Allows to ignore validation errors that typically occur with self-signed SSL certificates. Making this explicit is important as one would typically only use this in development or in-house deployments. This should also fix bug 1012591. Change-Id: I1210fafc9257648c902176fbcfae9d47e47fc557
Diffstat (limited to 'keystoneclient/shell.py')
-rw-r--r--keystoneclient/shell.py15
1 files changed, 13 insertions, 2 deletions
diff --git a/keystoneclient/shell.py b/keystoneclient/shell.py
index ef789f0..8990863 100644
--- a/keystoneclient/shell.py
+++ b/keystoneclient/shell.py
@@ -140,6 +140,15 @@ class OpenStackIdentityShell(object):
default=env('OS_KEY'),
help='Defaults to env[OS_KEY]')
+ parser.add_argument('--insecure',
+ default=False,
+ action="store_true",
+ help="Explicitly allow keystoneclient to perform "
+ "\"insecure\" SSL (https) requests. The "
+ "server's certificate will not be verified "
+ "against any certificate authorities. This "
+ "option should be used with caution.")
+
# FIXME(dtroyer): The args below are here for diablo compatibility,
# remove them in folsum cycle
@@ -308,7 +317,8 @@ class OpenStackIdentityShell(object):
self.cs = shell_generic.CLIENT_CLASS(endpoint=args.os_auth_url,
cacert=args.os_cacert,
key=args.os_key,
- cert=args.os_cert)
+ cert=args.os_cert,
+ insecure=args.insecure)
else:
token = None
endpoint = None
@@ -327,7 +337,8 @@ class OpenStackIdentityShell(object):
region_name=args.os_region_name,
cacert=args.os_cacert,
key=args.os_key,
- cert=args.os_cert)
+ cert=args.os_cert,
+ insecure=args.insecure)
try:
args.func(self.cs, args)