| commit | 592891bb6af1050567d688727cda7638eb8c9149 | [log] [tgz] |
|---|---|---|
| author | Eunchan Kim <eunchan@opentitan.org> | Thu Jan 30 09:36:33 2020 -0800 |
| committer | Eunchan Kim <eunchan@opentitan.org> | Thu Jan 30 11:11:49 2020 -0800 |
| tree | 0ff4f0218ce84cd36906779dd0a098ff8e3385ed | |
| parent | 7f559d90d521cb9ea7fea8061c58b1e3f3d08350 [diff] |
[hmac] Message Length calculated at prim_packer
Problem:
Received Message Length doesn't account the partial write to the
MSG_FIFO until `hash_process` is triggered.
As Jon addressed in the issue #1449, HMAC calculates the received
message length in front of the MSG_FIFO. Between the TL-UL port and the
MSG_FIFO, `prim_packer` module exists to support partial write without
alignment. While changing, the message length calculation logic didn't
move. So, it only updates when any writes happen to MSG_FIFO not to
`prim_packer`.
If partial write happens, `prim_packer` stores it until it becomes full
4 byte write or `hash_process` is triggered. So, this is not visible to
the recevied message length until above conditions happen.
Resolution:
Moved the message length calculation logic in front of the
`prim_packer`.
Signed-off-by: Eunchan Kim <eunchan@opentitan.org>
OpenTitan is an open source silicon Root of Trust (RoT) project. OpenTitan will make the silicon RoT design and implementation more transparent, trustworthy, and secure for enterprises, platform providers, and chip manufacturers. OpenTitan is administered by lowRISC CIC as a collaborative project to produce high quality, open IP for instantiation as a full-featured product. See the the OpenTitan site and OpenTitan docs for more information about the project.
This repository contains hardware, software and utilities written as part of the OpenTitan project. It is structured as monolithic repository, or “monorepo”, where all components live in one repository. It exists to enable collaboration across partners participating in the OpenTitan project.
The project contains comprehensive documentation of all IPs and tools. You can either access it online or build it locally by following the steps below.
$ sudo apt install curl python3 python3-pip $ pip3 install --user -r python-requirements.txt
$ ./util/build_docs.py --preview
This compiles the documentation into ./build/docs and starts a local server, which allows you to access the documentation at http://127.0.0.1:1313.
Have a look at CONTRIBUTING for guidelines on how to contribute code to this repository.
Unless otherwise noted, everything in this repository is covered by the Apache License, Version 2.0 (see LICENSE for full text).