Import Upstream version 4.12.4
This commit is contained in:
@@ -9,7 +9,9 @@ from base64 import b64encode
|
||||
|
||||
|
||||
# pylint: disable=relative-import
|
||||
from custodia.message.kem import KEMClient, KEY_USAGE_SIG, KEY_USAGE_ENC
|
||||
from ipaserver.custodia.message.kem import (
|
||||
KEMClient, KEY_USAGE_SIG, KEY_USAGE_ENC
|
||||
)
|
||||
# pylint: enable=relative-import
|
||||
from jwcrypto.common import json_decode
|
||||
from jwcrypto.jwk import JWK
|
||||
@@ -112,6 +114,7 @@ class CustodiaClient:
|
||||
headers = self._auth_header()
|
||||
|
||||
# Perform request
|
||||
# pylint: disable-next=missing-timeout
|
||||
r = requests.get(
|
||||
url, headers=headers,
|
||||
verify=paths.IPA_CA_CRT,
|
||||
|
||||
@@ -31,6 +31,9 @@ def export_key(args, tmpdir):
|
||||
'-out', pk12file,
|
||||
'-inkey', args.keyfile,
|
||||
'-password', 'file:{pk12pwfile}'.format(pk12pwfile=pk12pwfile),
|
||||
'-keypbe', 'AES-256-CBC',
|
||||
'-certpbe', 'AES-256-CBC',
|
||||
'-macalg', 'sha384',
|
||||
])
|
||||
|
||||
with open(pk12file, 'rb') as f:
|
||||
|
||||
@@ -13,8 +13,9 @@ from cryptography.hazmat.backends import default_backend
|
||||
from cryptography.hazmat.primitives import serialization
|
||||
from cryptography.hazmat.primitives.asymmetric import rsa, ec
|
||||
# pylint: disable=relative-import
|
||||
from custodia.message.kem import KEMKeysStore
|
||||
from custodia.message.kem import KEY_USAGE_SIG, KEY_USAGE_ENC, KEY_USAGE_MAP
|
||||
from ipaserver.custodia.message.kem import (
|
||||
KEMKeysStore, KEY_USAGE_SIG, KEY_USAGE_ENC, KEY_USAGE_MAP
|
||||
)
|
||||
# pylint: enable=relative-import
|
||||
from jwcrypto.common import json_decode, json_encode
|
||||
from jwcrypto.common import base64url_encode
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Copyright (C) 2017 IPA Project Contributors, see COPYING for license
|
||||
import argparse
|
||||
|
||||
import custodia.server # pylint: disable=relative-import
|
||||
import ipaserver.custodia.server # pylint: disable=relative-import
|
||||
|
||||
|
||||
argparser = argparse.ArgumentParser(
|
||||
@@ -23,7 +23,7 @@ argparser.add_argument(
|
||||
|
||||
|
||||
def main():
|
||||
return custodia.server.main(argparser)
|
||||
return ipaserver.custodia.server.main(argparser)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
@@ -4,7 +4,7 @@ from __future__ import print_function, absolute_import
|
||||
import os
|
||||
import sys
|
||||
|
||||
from custodia.plugin import CSStore
|
||||
from ipaserver.custodia.plugin import CSStore
|
||||
|
||||
from ipaplatform.paths import paths
|
||||
from ipaplatform.constants import constants
|
||||
|
||||
Reference in New Issue
Block a user