Generated banner for Doca Sha Offload Engine
Generated logo for Doca Sha Offload Engine

Doca Sha Offload Engine

NVIDIAOfficialCreated by NVIDIA

  • Skill
  • Tool integration
  • Software development
  • Apache-2.0
  • Medium risk

From the author

Use this skill when wiring the DOCA SHA Offload Engine (an OpenSSL ENGINE) into an existing OpenSSL pipeline to offload one-shot SHA-1, SHA-256, or SHA-512 (EVP_Digest) onto DOCA SHA hardware without rewriting against doca-sha. Covers engine load mechanics (`openssl engine dynamic`, `set_pci_addr` ctrl, `-engine_impl`), the SHA-224 negative test that proves offload engaged, the message-size window where offload beats CPU SHA, and engine-vs-library selection. Trigger even when the user does not say "DOCA SHA Offload Engine" or "OpenSSL ENGINE" — typical implicit phrasings: "speed up openssl SHA on BlueField", "offload SHA without code changes", "is openssl using the accelerator or falling back to software", "prove DOCA SHA actually ran", "openssl dgst hashed but I'm not sure it was offloaded". Refuse and route elsewhere for new SHA pipelines (use doca-sha), MD5 / SHA-3 / SHA-224 / HMAC-SHA offload, incremental hashing via chained `EVP_DigestUpdate`, or OpenSSL PROVIDER authoring.
— the description by NVIDIA

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

The DOCA SHA Offload Engine is an OpenSSL ENGINE that enables hardware-accelerated SHA hashing for existing OpenSSL-based applications without requiring source code modifications. It specifically targets one-shot SHA-1, SHA-256, and SHA-512 operations via the EVP_Digest interface. This skill provides guidance on loading the engine, configuring the PCIe address, verifying that offload is active, and determining when hardware acceleration provides a performance benefit over CPU-based hashing.

What it does

  • Provides mechanics for loading the engine into OpenSSL pipelines.
  • Explains how to configure the engine using the set_pci_addr control command.
  • Outlines verification patterns to confirm offload is active versus software fallback.
  • Defines the supported SHA algorithms and the engine's behavior for unsupported types.
  • Offers guidance on comparing performance between the engine and standard CPU SHA.
  • Details the engine-vs-library selection criteria for new versus existing pipelines.

When to use it

  • When you need to accelerate SHA hashing in an existing OpenSSL-based application.
  • When you want to avoid rewriting code to use the native doca-sha library.
  • When you need to verify if your current OpenSSL pipeline is successfully using the DPU hardware.
  • When you are evaluating if the message-size of your workload benefits from hardware offload.
  • When you need to troubleshoot engine loading or performance issues on a BlueField-2 DPU.

Advantages

  • Enables hardware acceleration without modifying existing application source code.
  • Integrates seamlessly with standard OpenSSL EVP_Digest workflows.
  • Provides clear verification tests to ensure offload is actually occurring.
  • Allows for performance optimization by identifying the optimal message-size window.
  • Maintains compatibility with standard OpenSSL engine loading mechanisms.

Usage examples

“How can I offload SHA-256 in my existing OpenSSL application without rewriting it?”
The agent will guide you through loading the libdoca_sha_offload_engine.so shared object into your OpenSSL pipeline using the engine dynamic interface.
“How do I verify that my OpenSSL command is actually using the DOCA SHA engine?”
The agent will instruct you to perform a negative test using an unsupported digest like SHA-224 to ensure the engine does not silently fall back to software.
“Is the DOCA SHA engine faster than CPU SHA for my 4KB data blocks?”
The agent will provide the openssl speed comparison pattern to help you measure the performance impact on your specific hardware and workload.

Install

  1. Download the skill as a ZIP:

    https://mp-staging.autogineer.com/agent-skills/nvidia/doca-sha-offload-engine/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip doca-sha-offload-engine.zip -d .agents/skills

Documentation by NVIDIA

DOCA SHA Offload Engine

Examples

  • “Can I offload SHA in an existing OpenSSL pipeline without rewriting?” — this is in scope. Load the engine; do not start a new doca-sha pipeline here.

  • “How do I prove OpenSSL used DOCA SHA, not CPU SHA?” — use the SHA-224 negative test; do not treat a successful digest as proof of offload.

Quick answer (answer from this file)

  1. Device gate first. The DOCA SHA engine exists only on BlueField-2; BlueField-3 has no SHA acceleration engine (public DOCA SHA guide), so there is nothing to offload there: say so and stop.

  2. Load probe: openssl engine dynamic -pre NO_VCHECK:1 -pre SO_PATH:<engine .so> -pre LOAD -vvv -t -c.

  3. Positive test: openssl dgst -sha256 -engine <engine .so> -engine_impl <file> reports the engine was set.

  4. Negative test: an unsupported digest (-sha224) must fail with the engine selected; it must not silently fall back.

  5. Performance: compare openssl speed -evp sha256 with and without the engine (add -async_jobs for parallelism). Report measured numbers only; never quote numbers from memory.

Instructions

Follow Loading order below. Open the tasks companion for configure / run. Open the capabilities companion for when offload wins and how to verify it. Do not open every companion file.

Where to start: This is a tool skill for the OpenSSL ENGINE installed by the doca-sha-offload-engine package under ${DOCA_DIR}/tools/doca_sha_offload_engine/ as libdoca_sha_offload_engine.so, next to its engine_readme.md. It is not a CLI — it is a shared object loaded by an OpenSSL-based application or by openssl itself, that re-routes SHA-1 / SHA-256 / SHA-512 (one-shot only, via the EVP_Digest interface) onto the DOCA SHA hardware path. Open the tasks companion and start at ## configure for the PCIe-address configuration and the OpenSSL prerequisites; jump to ## run for the “load the engine and prove it actually runs” flow. Open the capabilities companion when the question is what the engine actually offloads vs falls back to, when the engine is a perf win vs not, or how to verify offload actually engaged. If DOCA is not installed yet, route to doca-setup/SKILL.md first. If the user is building a new SHA pipeline from scratch (not wrapping an existing OpenSSL-based one), this skill is the wrong surface — route to ../../libs/doca-sha/SKILL.md (doca-sha/SKILL.md) instead.

Example questions this skill answers well

The CLASSES of doca-sha-offload-engine questions this skill is built to answer, each with one worked example. The class is the load-bearing piece; the worked example is one instance.

  • “I have an existing OpenSSL-based pipeline doing SHA; can I offload the SHA to DOCA without rewriting the app?” — worked example: “the app uses EVP_DigestInit_ex / EVP_DigestUpdate / EVP_DigestFinal_ex against EVP_sha256(); can I drop in DOCA-SHA offload via an engine load?”. Answered by the “when this engine is the right surface” rule in the capabilities companion

    • the engine-load mechanics in the tasks companion.

  • “Did the engine actually load? Or did OpenSSL just fall back to software SHA?” — worked example: “my openssl dgst invocation completed; how do I know DOCA SHA actually did the work and OpenSSL did not silently use the software path?”. Answered by the “prove the engine actually ran” pattern in the capabilities companion (the SHA-224 negative test and the -engine_impl flag) + the verification flow in the tasks companion.

  • “For what message-size range is the engine offload a win vs CPU SHA?” — worked example: “my pipeline hashes 4 KB blocks at a time; is the engine a win there, or does the round-trip to DOCA SHA cost more than the CPU hash itself?”. Answered by the message-size-window rule in the capabilities companion

    • the openssl speed perf-comparison pattern in the tasks companion.

  • “What SHA algorithms does the engine actually support — and what happens for the ones it does not?” — worked example: “my pipeline mixes SHA-1, SHA-256, SHA-512, and SHA-224 — what does the engine do for each?”. Answered by the algorithm-coverage matrix in the capabilities companion.

  • “Should I use this engine, or call doca-sha directly?” — worked example: “I am writing a new service from scratch; does the engine save me work or does it add complexity I do not need?”. Answered by the “engine vs library” selection table in the capabilities companion.

  • “What OpenSSL versions does the engine require, and what about OpenSSL 3.x's deprecation of the ENGINE API?” — worked example: “my host has OpenSSL 3.0; will the engine still load?”. Answered by the version overlay in the capabilities companion (verified surface: the engine is documented for OpenSSL 1.1.1f on Ubuntu 20.04 and OpenSSL 3.0.2 on Ubuntu 22.04 per the shipped engine_readme.md).

When to load this skill

Load this skill when the user is — or the agent needs to — deploy the DOCA SHA Offload Engine into an OpenSSL-based pipeline on a host with DOCA installed and a SHA-capable device. Concretely:

  • Wiring the engine into an existing OpenSSL-based application or openssl CLI invocation, with the intent of no source-level code changes (or only the minimum ENGINE_load_dynamic / ENGINE_by_id block shown in the shipped engine_readme.md).

  • Verifying the engine actually engaged for the hot-path digests (the “is offload real or did OpenSSL fall back to software” question).

  • Characterizing the message-size range over which the engine is a perf win vs the CPU sha1 / sha256 / sha512 paths.

  • Deciding between “adopt the engine” (existing pipeline, minimal change) and “rewrite to doca-sha” (new pipeline, fine-grained control needed).

Do not load this skill for users building a new SHA-pipeline from scratch — route to ../../libs/doca-sha/SKILL.md (doca-sha/SKILL.md). Do not load this skill for users wanting algorithms the engine does not implement (MD5, SHA-3, SHA-224, HMAC-SHA, streaming/incremental SHA via EVP_DigestUpdate chains that the engine treats as one-shot only).

What this skill provides

This is a thin loader. Substantive material lives in two companion files:

  • the capabilities companion — what the engine offloads (verified: one-shot SHA-1, SHA-256, SHA-512 via the OpenSSL EVP_Digest high-level interface), what it does NOT offload (anything else — including SHA-224, MD5, SHA-3, HMAC-SHA, and any chained EVP_DigestInit_ex / EVP_DigestUpdate / EVP_DigestFinal_ex pattern that the engine implements by buffering and then calling DOCA SHA in one shot at Final), the engine-vs-library selection rule, the message-size-window rule for when offload is a perf win, the verified ctrl-cmd surface (set_pci_addr), the version overlay (OpenSSL ≥ 1.1.1; the shipped engine_readme.md documents testing on OpenSSL 1.1.1f and 3.0.2; OpenSSL 3.x deprecates the ENGINE API but still supports it via the legacy code path), the layered error taxonomy, the observability surface (the “prove offload engaged” pattern using the SHA-224 negative test and -engine_impl), and the safety overlay.

  • the tasks companion — step-by-step workflows for the in-scope task verbs: install, configure (PCIe address selection — the engine defaults to 03:00.0 and exposes the set_pci_addr ctrl-cmd), build (none: the package ships the engine pre-built), modify (refuses engine patching; modify the load-time invocation and the PCIe address instead), run (load the engine via openssl engine dynamic; the verification pattern; the OpenSSL programmatic ENGINE_load_dynamic block), test (the “prove the engine ran” SHA-224 negative test; the openssl speed perf comparison; the message-size window characterization), debug (walk the error taxonomy layer by layer), use (the engine-vs-library decision for the user's specific pipeline), plus a Deferred task verbs block.

The skill assumes a host where DOCA is already installed, OpenSSL ≥ 1.1.1 is present (libssl-dev or equivalent), and the deploying user can access the selected DOCA SHA PCIe device. Verify device visibility and run the engine-load smoke as that same user before integration; if either fails with a permission error, stop and route to doca-setup rather than guessing a group, ACL, or sudo policy.

What this skill deliberately does not ship

This skill is agent guidance, not a samples or scripts bundle. It deliberately does not contain — and pull requests should not add:

  • Pre-written OpenSSL ENGINE application source code beyond the verbatim block in the shipped engine_readme.md (the ENGINE_load_dynamic / ENGINE_by_id / ENGINE_ctrl_cmd_string / ENGINE_init / ENGINE_set_default_digests sequence, cross-referenced into the tasks companion). The shipped readme is the worked example.

  • A samples/, bindings/, or reference/ subtree. This is a thin loader for a shipped shared-object; substantive material lives in the shipped engine_readme.md and the doca-sha library docs.

  • Performance numbers from agent memory. The message-size-window where the engine wins is device-, firmware-, OpenSSL-version-, and workload-specific. The openssl speed comparison pattern in the tasks companion is the way to capture it on the user's actual hardware; quoting a number from memory is the cross-platform failure mode this skill exists to prevent.

  • Wrappers, parsers, or scripts in any language that consume the engine's stdout or the openssl speed output format.

Loading order

  1. Read this skill first to confirm the user's question is in scope (the user actually has an existing OpenSSL-based pipeline and wants to offload to DOCA SHA without code changes; if the user is building from scratch, route to ../../libs/doca-sha/ (doca-sha/SKILL.md)).

  2. For what the engine offloads vs falls back, the engine-vs-library selection rule, the message-size- window rule, the version overlay, the error taxonomy, the observability surface (and the prove-offload- actually-engaged pattern), and the safety overlay, see the capabilities companion.

  3. For step-by-step workflows — install, configure, build, modify, run, test, debug, use — see the tasks companion.

  • ../../libs/doca-sha/SKILL.md (doca-sha/SKILL.md) — the underlying DOCA SHA library. The engine is a thin OpenSSL-ENGINE wrapper around doca-sha; when the user needs fine-grained control over the SHA task surface (partial-hash, custom buffer permissions, cap-query for unusual message sizes), the library is the right answer. The engine wraps the one-shot task; the library exposes both one-shot and partial- hash per doca-sha/SKILL.md.

  • doca-version/SKILL.md — the canonical version-detection chain. The engine has a TWO-axis version overlay (DOCA-side and OpenSSL-side); the version skill carries the four-way match rule this skill layers on top of.

  • doca-debug/SKILL.md — the cross-cutting debug ladder. The engine surfaces its own error taxonomy; when the cause is below DOCA (driver, firmware), the taxonomy hands off here.

  • doca-setup/SKILL.md — env preparation, install verification, the libssl-dev install path, and the NGC DOCA container path.

  • doca-public-knowledge-map/SKILL.md — routing to the public DOCA SHA documentation set on docs.nvidia.com/doca/sdk/ and to the OpenSSL ENGINE / openssl-engine upstream documentation on openssl.org.

  • doca-hardware-safety/SKILL.md — the bundle-wide hardware-safety meta-policy. The engine binds to a specific PCIe device; the set_pci_addr ctrl is the artifact-specific overlay, but any host-side change underneath (firmware burn, BFB reflash) runs through the meta-policy.

Files

CAPABILITIES.md

DOCA SHA Offload Engine — Capabilities

Where to start: This file is loaded by SKILL.md. It documents what the engine actually offloads vs falls back, when the engine is the right surface vs the underlying doca-sha library, which OpenSSL + DOCA combinations it requires, the layered error and observability surfaces, the message-size window in which the engine is a perf win, and the safety overlay. The pattern overview names the recurring engine-class questions; pick the pattern first, then drill into the H2 that owns the substance. For the how, jump to TASKS.md.

Pattern overview

Every doca-sha-offload-engine-class question this skill teaches resolves into one of six patterns.

Engine patternClass shapeWhere the substance lives
1. Pick engine vs doca-sha directlyDecide before writing any code (or before wiring the engine into the deployment) whether the OpenSSL ENGINE wrapper is the right answer or whether the application should call doca-sha directly. The engine is right for existing pipelines wanting offload with no code change; doca-sha is right for new pipelines or for fine-grained control.## Capabilities and modes engine-vs-library selection table
2. Configure the PCIe addressThe engine defaults to PCIe address 03:00.0 (shipped engine_readme.md example); on systems where DOCA SHA lives at a different PCIe address, the operator sets the run-time set_pci_addr ctrl-cmd.## Capabilities and modes PCIe-address configuration + TASKS.md ## configure
3. Load and register the engineThe engine is loaded through OpenSSL's standard ENGINE API — either via openssl engine dynamic -pre LOAD ... for CLI usage or via ENGINE_load_dynamic / ENGINE_by_id / ENGINE_ctrl_cmd_string / ENGINE_init / ENGINE_set_default_digests for programmatic usage. The verified load pattern is in the shipped engine_readme.md.## Capabilities and modes engine-load pattern + TASKS.md ## run
4. Prove offload actually engagedA successful openssl dgst does NOT prove the engine ran — OpenSSL falls back to software SHA when the engine is missing or fails to register. The “SHA-224 negative test” + the -engine_impl flag are the verified proofs that the engine was actually called.## Observability prove-offload pattern + TASKS.md ## test
5. Characterize the message-size winThe engine offload adds round-trip cost to each digest; for small messages CPU SHA wins, for large messages (especially with -async_jobs) the engine wins. The crossover point is workload- and platform-specific.## Capabilities and modes message-size-window rule + TASKS.md ## test
6. Diagnose a load / digest failureWalk the layered error taxonomy — load-layer (engine .so not found, OpenSSL version mismatch) / register-layer (engine loaded but digests not registered, PCIe address rejected) / runtime-layer (engine engaged but a specific digest call failed) / version / cross-cutting (driver, firmware, NUMA).## Error taxonomy + TASKS.md ## debug

Two cross-cutting rules that apply to every pattern above:

  • A successful invocation does not prove offload. Without the “SHA-224 negative test” or the -engine_impl flag (which disables OpenSSL's software fallback when the engine does not implement a digest), the operator cannot tell whether DOCA SHA ran or whether OpenSSL silently used its built-in SHA. The prove-offload pattern is the load-bearing primitive of this skill — the verified pattern lives in ## Observability and the worked example lives in the shipped engine_readme.md.

  • The engine offloads ONLY one-shot SHA-1 / SHA-256 / SHA-512. Per the shipped engine_readme.md, the engine offloads OpenSSL SHA-1, SHA-256 and SHA-512 and is built on the EVP_Digest one-shot interface. Anything else — SHA-224, MD5, SHA-3, HMAC-SHA, true incremental SHA via repeated EVP_DigestUpdate — is either silently handled by OpenSSL's software path (without -engine_impl) or fails (with -engine_impl). The shipped engine_readme.md documents this surface explicitly.

Capabilities and modes

The DOCA SHA Offload Engine is a dynamic OpenSSL ENGINE shipped as libdoca_sha_offload_engine.so under ${DOCA_DIR}/tools/doca_sha_offload_engine/, using DOCA's doca-sha library and OpenSSL ≥ 1.1.1. There is no daemon, no CLI of its own, and no programmatic API specific to the engine; the surface is the OpenSSL ENGINE API.

Algorithm-coverage matrix

Per the shipped engine_readme.md:

OpenSSL EVP digestWhat the engine does
EVP_sha1()Offloads to DOCA SHA (one-shot, via the EVP_Digest interface).
EVP_sha256()Offloads to DOCA SHA (one-shot).
EVP_sha512()Offloads to DOCA SHA (one-shot).
EVP_sha224(), EVP_sha384(), EVP_sha3_*, EVP_md5()NOT offloaded. Without -engine_impl, OpenSSL falls back to its built-in software SHA. With -engine_impl, the digest call fails (this is the basis of the "prove offload actually engaged" pattern).
Streaming / chained EVP_DigestInit_ex → EVP_DigestUpdate → EVP_DigestFinal_exPer the shipped engine_readme.md, the engine is built on the one-shot EVP_Digest API. Chained-update workflows that OpenSSL's library code paths convert to one-shot may still be offloaded; workflows that genuinely require incremental hashing are outside the engine's surface — route to ../../libs/doca-sha/CAPABILITIES.md (doca-sha/CAPABILITIES.md) and the partial-hash task there.
Engine vs library: selection rule
User situationRight surfaceWhy
Existing OpenSSL-based pipeline doing SHA-1 / SHA-256 / SHA-512; wants offload with no code changeThis engine.Drop in via the openssl engine dynamic load pattern; the only application change is the ENGINE_load_dynamic block from the shipped engine_readme.md, or even less if the user can rely on an openssl.cnf engines section.
New SHA-using pipeline being authored from scratch../../libs/doca-sha/ (doca-sha/SKILL.md).The library exposes both one-shot and partial-hash tasks, the full cap-query surface, and the DOCA Core context lifecycle. The engine is a deliberate subset; the library is the full surface.
Existing OpenSSL pipeline needing offload for an algorithm the engine does NOT cover (SHA-224, SHA-3, HMAC-SHA)Neither this engine, nor doca-sha directly for that algorithm.DOCA SHA's library surface is documented per ../../libs/doca-sha/CAPABILITIES.md (doca-sha/CAPABILITIES.md); the engine restricts to one-shot SHA-1 / 256 / 512. The agent surfaces the gap honestly.
Existing pipeline that requires TRUE incremental hashing (gigabytes-into-one-digest with chunks too large for one DOCA SHA task)../../libs/doca-sha/ (doca-sha/SKILL.md) directly, using the partial-hash task.The engine's one-shot path requires the full message fit in a single DOCA SHA call; the partial-hash task in the library exists for exactly this case.

The selection rule is the load-bearing piece. The agent must surface the engine-vs-library choice to the user before recommending the engine.

PCIe-address configuration

The engine binds the DOCA SHA device at PCIe address 03:00.0 by default (the shipped engine_readme.md example). To use a different device:

  1. Run-time override via the set_pci_addr ctrl-cmd. The engine lists a ctrl-cmd named set_pci_addr (STRING input) in its openssl engine -vvv output; it sets the PCIe address at engine init time. The CLI invocation pattern is openssl engine dynamic -pre SO_PATH:... -pre LOAD -pre "set_pci_addr:<bdf>"; the programmatic equivalent is ENGINE_ctrl_cmd_string(e, "set_pci_addr", "<bdf>", 0) per the shipped engine_readme.md.

The agent's rule: surface the 03:00.0 default and the set_pci_addr override to the user. On stock installs 03:00.0 may or may not be the right device; the operator must check (doca_caps --list-devs or platform-specific PCIe inspection per doca-setup/SKILL.md).

Engine-load pattern (the verified surface)

Two load patterns, both verified in the shipped engine_readme.md:

  1. CLI:

    openssl engine dynamic \
        -pre NO_VCHECK:1 \
        -pre SO_PATH:${DOCA_DIR}/tools/doca_sha_offload_engine/libdoca_sha_offload_engine.so \
        -pre LOAD \
        -vvv -t -c

    On success the loader prints the engine name (doca_sha_offload_engine), the available digests ([SHA1, SHA256, SHA512]), and the set_pci_addr ctrl-cmd descriptor.

  2. Programmatic: per the shipped readme,

    ENGINE *e;
    const char *doca_engine_path = "${DOCA_DIR}/tools/doca_sha_offload_engine/libdoca_sha_offload_engine.so";
    ENGINE_load_dynamic();
    e = ENGINE_by_id(doca_engine_path);
    ENGINE_ctrl_cmd_string(e, "set_pci_addr", doca_engine_pci_addr, 0);
    ENGINE_init(e);
    ENGINE_set_default_digests(e);

    Unload mirrors it: ENGINE_unregister_digests(e) → ENGINE_finish(e) → ENGINE_free(e).

The agent quotes the shipped path verbatim (${DOCA_DIR}/tools/doca_sha_offload_engine/libdoca_sha_offload_engine.so) rather than inventing one.

Message-size window: when offload is a perf win

The engine offload adds a round-trip cost (the engine hands the message to DOCA SHA, waits for completion, returns to the OpenSSL caller). For small messages the round-trip cost dominates the SHA compute itself; for large messages it amortizes. Three sub-classes:

Message size classTypical engine vs CPU resultTuning that matters
Small (e.g. ~10 KB)CPU SHA may match or beat the engine without -async_jobs; -async_jobs enables asynchronous engine batching and changes the picture per the shipped engine_readme.md openssl speed examples.-async_jobs 256 (or workload-appropriate value); -multi <N> for multi-threaded scaling.
Medium (e.g. ~100 KB)Engine + -async_jobs typically wins.-async_jobs.
Large (e.g. ≥1 MB)Engine wins comfortably, even synchronous.The shipped engine_readme.md examples use 10 000-byte messages with and without -async_jobs 256 and -multi 8.

The exact crossover point depends on the DOCA SHA device, the CPU's SHA-instruction-set support (SHA-NI), the OpenSSL version, and the workload's concurrency. The agent does NOT quote a crossover from memory; the openssl speed comparison pattern in TASKS.md ## test is the way to capture it on the user's actual hardware.

Version compatibility

Device gate: the SHA engine exists only on BlueField-2; BlueField-3 has no SHA acceleration engine, so the offload engine cannot accelerate there.

For the canonical DOCA version-detection chain, the four-way match rule, NGC container semantics, and the headers-win-over-docs rule, see doca-version/SKILL.md. The body lives there; this skill does not duplicate it.

The doca-sha-offload-engine-specific overlay is:

  • The engine depends on doca-sha (the package depends on doca-sdk-sha). The version of the installed doca-sha (pkg-config --modversion doca-sha) is the authoritative DOCA-side pin. The four-way match across doca-common, doca-sha, and the rest of the install must hold per doca-version CAPABILITIES.md ## Version compatibility (doca-version/CAPABILITIES.md#version-compatibility).

  • OpenSSL ≥ 1.1.1 per the shipped engine_readme.md. The shipped engine_readme.md documents testing on OpenSSL 1.1.1f (Ubuntu 20.04) and OpenSSL 3.0.2 (Ubuntu 22.04). OpenSSL 3.x deprecates the ENGINE API in favor of PROVIDERS, but still supports ENGINEs via the legacy code path (per the OpenSSL upstream documentation on openssl.org/docs/manmaster/man7/migration_guide.html). The engine will continue to load on OpenSSL 3.x; the load pattern is unchanged.

  • The ENGINE-vs-PROVIDER question. This skill does not ship a PROVIDER version of the offload (the shipped artifact is an ENGINE, not a PROVIDER). On a pure OpenSSL 3.x deployment where the operator has moved to PROVIDERS exclusively, the engine still works (legacy code path) but is not the long-term answer; the agent surfaces that as a forward-looking concern without inventing a PROVIDER artifact that does not exist.

  • OpenSSL development headers (libssl-dev on Ubuntu, openssl-devel on RHEL) are needed only by applications that call the ENGINE API programmatically. The agent routes the package-name lookup through doca-setup/SKILL.md rather than quoting from memory.

  • No version literal from memory for DOCA. The agent quotes versions observed from the user's host.

Error taxonomy

The engine's error surface combines the OpenSSL load / register path with the DOCA SHA runtime path. The layers, in escalating order:

  1. Load-layer. openssl engine dynamic -pre LOAD ... (or ENGINE_load_dynamic / ENGINE_by_id) fails to find or open the .so. Causes: wrong SO_PATH, missing OpenSSL headers / ABI mismatch (the engine was built against one OpenSSL version and is being loaded by another), missing transitive dependencies (the engine's .so pulls in libdoca_sha.so and other DOCA shared objects). Routing: confirm the path is the verified ${DOCA_DIR}/tools/doca_sha_offload_engine/libdoca_sha_offload_engine.so; run ldd on the engine .so to surface missing dependencies; confirm the OpenSSL on the host matches the OpenSSL the engine was built against.

  2. Register-layer. Engine loaded but the digests are not registered, OR the set_pci_addr ctrl-cmd was rejected, OR ENGINE_set_default_digests returns failure. Causes: the configured PCIe address is not a valid DOCA SHA device; the device exists but DOCA cannot bind it (driver / firmware precondition not met). Routing: verify the device via doca_caps --list-devs; route to doca-caps TASKS.md ## run (doca-caps/TASKS.md#run) for the capability snapshot.

  3. Runtime-layer. Engine registered; a specific digest call returns an error. Common sub-causes: message size exceeds the DOCA SHA cap-reported maximum source buffer size (per ../../libs/doca-sha/CAPABILITIES.md#capabilities-and-modes (doca-sha/CAPABILITIES.md#capabilities-and-modes) doca_sha_cap_get_max_src_buf_size); destination buffer too small; transient device errors. The engine reports these through DOCA logging.

  4. Engine-not-engaged (silent fallback). The openssl dgst call completed and produced a correct hash, but DOCA SHA never ran — OpenSSL fell back to software SHA because the engine was not loaded, the engine was loaded but the digest was not in [SHA1, SHA256, SHA512], or the engine was loaded but ENGINE_set_default_digests was not called. This is the most common silent failure mode for this skill and is the reason the -engine_impl / SHA-224 verification pattern exists per ## Observability.

  5. Version. Cross-cutting partial-install / mixed-version per doca-version CAPABILITIES.md ## Version compatibility (doca-version/CAPABILITIES.md#version-compatibility). OpenSSL 1.1.1 vs 3.x; DOCA versions across host vs container.

  6. Cross-cutting. Cause is below DOCA — mlx5 driver, firmware on the SHA-capable device, hugepages, NUMA. Route to doca-debug TASKS.md ## debug (doca-debug/TASKS.md#debug) and doca-setup TASKS.md ## debug (doca-setup/TASKS.md#debug).

For the cross-library DOCA_ERROR_* taxonomy, see doca-programming-guide CAPABILITIES.md ## Error taxonomy (doca-programming-guide/CAPABILITIES.md#error-taxonomy).

Observability

The engine's observability surface combines OpenSSL-side visibility (the openssl engine dynamic loader's verbose output) with DOCA-side logging. Specifically:

  • openssl engine dynamic -vvv -t -c output. On successful load the verified output per the shipped engine_readme.md prints the engine name, the available digests ([SHA1, SHA256, SHA512]), the [available] marker, and the set_pci_addr ctrl-cmd descriptor. This is the agent's first observability signal — “did the engine load and register the right digests?”.

  • The “prove offload actually engaged” pattern. This is the load-bearing observability primitive of this skill. Two techniques, using the shipped engine_readme.md invocations:

    • -engine_impl for an algorithm the engine supports. Run openssl dgst -sha256 -engine <path> -engine_impl; -engine_impl disables OpenSSL's software fallback, so a successful output proves the engine actually computed the hash.

    • The SHA-224 negative test. Run openssl dgst -sha224 -engine <path> -engine_impl; SHA-224 is NOT in the engine's covered set, and the -engine_impl flag prevents OpenSSL from falling back to software SHA. The expected output is an error; the error PROVES OpenSSL actually consulted the engine and the engine did not implement SHA-224. Without this test, the operator cannot distinguish “the engine works” from “OpenSSL is silently using software SHA”.

  • openssl speed for performance characterization. Per the shipped engine_readme.md, the documented invocations use openssl speed -evp <alg> -bytes <N> -elapsed with and without --engine <path>. The agent runs both, with and without -async_jobs, to characterize the message-size window per ## Capabilities and modes.

  • DOCA log levels. DOCA_LOG_LEVEL applies per doca-debug CAPABILITIES.md ## Observability (doca-debug/CAPABILITIES.md#observability). The engine reports its own diagnostics through DOCA logging.

  • ldd <engine.so> for the load-layer check. Useful when the engine fails to load and the operator needs to confirm transitive dependencies are present.

For env-side observability (PCIe scans, firmware introspection) see doca-setup CAPABILITIES.md ## Observability (doca-setup/CAPABILITIES.md#observability). For doca-sha-library-side observability see ../../libs/doca-sha/CAPABILITIES.md#observability (doca-sha/CAPABILITIES.md#observability).

Safety policy

Overlay on the bundle-wide hardware-safety meta-policy. The rules below are this skill's per-artifact overlay on the cross-cutting rules in doca-hardware-safety CAPABILITIES.md ## Safety policy (doca-hardware-safety/CAPABILITIES.md#safety-policy) (specifically ### Per-artifact overlay pattern (doca-hardware-safety/CAPABILITIES.md#per-artifact-overlay-pattern)). When the two layers disagree, the stricter wins; when either layer says STOP, the agent stops.

The engine binds to a specific PCIe device (the DOCA SHA accelerator) and runs as a shared object loaded by the application's OpenSSL. The artifact-specific overlay:

  • Verify offload before quoting any perf claim. The prove-offload pattern in ## Observability is the load-bearing safety primitive of this skill. Quoting a “DOCA SHA offload win” without first running the SHA-224 negative test or the -engine_impl flag is the canonical “we measured the wrong thing” failure mode — the operator may be benchmarking OpenSSL's software SHA against itself.

  • PCIe-address binding is a credential. The set_pci_addr ctrl points the engine at a specific device; on multi-tenant hosts where multiple accelerators exist, the operator must confirm the chosen PCIe address belongs to the workload's intended device. Routing through doca-caps/SKILL.md and doca-setup/SKILL.md is the agent's first move.

  • OpenSSL 3.x deprecation warnings are not blockers but they are signals. Loading an ENGINE on OpenSSL 3.x may log deprecation warnings per OpenSSL's upstream guidance. The engine still functions; the agent surfaces the deprecation as a forward-looking concern (PROVIDERS are the OpenSSL 3.x answer) but does not invent a PROVIDER artifact that the bundle does not ship.

  • Do not invent OpenSSL flags or engine ctrl-cmds. The verified surface is -pre NO_VCHECK:1, -pre SO_PATH:..., -pre LOAD, -pre "set_pci_addr:...", -vvv -t -c, -engine <path>, -engine_impl, -async_jobs <N>, -multi <N>. Anything beyond those is either application-side OpenSSL surface (route via doca-public-knowledge-map/SKILL.md to the OpenSSL upstream docs on openssl.org) or a hallucination.

  • Hardware-safety meta-policy applies to host-side changes. Any host-side change the engine needs to cope with — firmware burn on the SHA-capable device, BlueField BFB reflash, host kernel boot parameter changes — runs through the cross-cutting meta-policy in doca-hardware-safety/SKILL.md, not through this engine's load-pattern.

Public-source pointer

The canonical public sources for this engine are:

  • The DOCA SHA programming guide page on docs.nvidia.com/doca/sdk/, reached via doca-public-knowledge-map/SKILL.md.

  • The OpenSSL ENGINE upstream documentation on openssl.org/docs/man1.1.1/man1/openssl-engine.html and the EVP_Digest man page at openssl.org/docs/manmaster/man3/EVP_Digest.html (both cited in the shipped engine_readme.md).

  • The shipped engine_readme.md next to the engine under ${DOCA_DIR}/tools/doca_sha_offload_engine/.

Do not invent OpenSSL flags, engine ctrl-cmd names, DOCA SHA symbols, or message-size crossover literals beyond what those sources document.

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

The author says: Requires DOCA SDK installed at /opt/mellanox/doca on Linux (Ubuntu 22.04/24.04 or RHEL/SLES) with a BlueField-2 DPU (not BF-3) attached, plus OpenSSL ≥ 1.1.1 (libssl-dev for ENGINE API callers) on the build host. The engine ships under /opt/mellanox/doca/tools/doca_sha_offload_engine/ as libdoca_sha_offload_engine.so; reads the user's local install via `pkg-config doca-sha` and inspects /opt/mellanox/doca/{lib,include,samples,applications}. The validation steps require a live DOCA install.

Security

What our scanner noticed· Medium risk

  • Large base64-encoded blobs

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Created by
NVIDIA
Publisher
NVIDIA (Official)
Source
NVIDIA/skills · skills/doca-sha-offload-engine · commit fce3cca
Licence
Apache License 2.0 (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE-APACHE)
  • ATTRIBUTION.md (written by AutoGineer)
Synced

AutoGineer is not affiliated with or endorsed by NVIDIA.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download doca-sha-offload-engine.zip