mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2026-10-12 08:24:52 -05:00
Fix http(s)_request in dogtag. Was blowing up because of unicode strings.
This commit is contained in:
1 parent
918721c1d0
commit
9dd082eb33
1 file changed
+4
@@ -66,6 +66,8 @@ def https_request(host, port, url, secdir, password, nickname, **kw):
|
||||
|
||||
Perform a client authenticated HTTPS request
|
||||
"""
|
||||
if isinstance(host, unicode):
|
||||
host = host.encode('utf-8')
|
||||
uri = 'https://%s:%d%s' % (host, port, url)
|
||||
post = urlencode(kw)
|
||||
logging.info('sslget %r', uri)
|
||||
@@ -101,6 +103,8 @@ def http_request(host, port, url, **kw):
|
||||
|
||||
Perform an HTTP request.
|
||||
"""
|
||||
if isinstance(host, unicode):
|
||||
host = host.encode('utf-8')
|
||||
uri = 'http://%s:%s%s' % (host, port, url)
|
||||
post = urlencode(kw)
|
||||
logging.info('request %r', uri)
|
||||
|
||||
Reference in new issue
Block a user