mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-09 00:51:29 +00:00
Add support for P256 based hybrid encryption, and corresponding tests. Where hybrid encryption is: P256 based DH + AES128 + HMAC-SHA256. BRANCH=none BUG=chrome-os-partner:43025,chrome-os-partner:47524 CQ-DEPEND=CL:336091,CL:339561 TEST=ECIES tests in test/tpm/tpmtest.py pass Change-Id: Ie091e278df72185a6896af0e498925e56404f87e Signed-off-by: nagendra modadugu <ngm@google.com> Reviewed-on: https://chromium-review.googlesource.com/337340 Commit-Ready: Nagendra Modadugu <ngm@google.com> Tested-by: Nagendra Modadugu <ngm@google.com> Reviewed-by: Marius Schilder <mschilder@chromium.org>
20 lines
454 B
Python
20 lines
454 B
Python
#!/usr/bin/python
|
|
# Copyright 2015 The Chromium OS Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
# found in the LICENSE file.
|
|
|
|
"""Subcommand codes that specify the crypto module."""
|
|
|
|
# Keep these codes in sync with include/extension.h.
|
|
AES = 0
|
|
HASH = 1
|
|
RSA = 2
|
|
EC = 3
|
|
FW_UPGRADE = 4
|
|
HKDF = 5
|
|
ECIES = 6
|
|
|
|
# The same exception class used by all tpmtest modules.
|
|
class TpmTestError(Exception):
|
|
pass
|