Skip to content

fiskaltrust/middleware-wrapper-atrust

Repository files navigation

A-Trust interface wrapper for the fiskaltrust.Middleware

By using this native library, users who have already had implemented the A-Trust Cloud TSE can continue to use their existing implementation of A-Trust's interface to connect the fiskaltrust.Middleware's SCU packages. In Germany, our Signature Creation Units (SCUs) provide well-proven implementations of all currently certified TSEs.

While those SCUs are normally used by our Middleware, it's also easily possible to operate them as "stand-alone" services. If you're interested in switching to a different Cloud TSE supported by the fiskaltrust.Middleware and/or this wrapper, please reach out to our sales team or visit one of our frequent webinars.

Usage

  1. Download the latest binaries for your target OS's architecture (x64/x86) from the releases page or build the binaries from source.
  2. Replace the original DLL of A-Trust with this DLL.
  3. Configure and download an SCU in the fiskaltrust.Portal
  4. Alter the included asigntseonline.conf and set the scu_url parameter to the REST endpoint that was configured for the SCU.
    [default]
    scu_url = http://localhost:5000/<url-as-configured-in-portal>
  5. Continue to use your existing implementation as-is.

Please refer to our documentation platform about how to onboard PosOperators and creating and rolling out Middleware instances (SCUs).

Building from source

Prerequisites

  • A rust compiler (tested with version >= 1.54)

Build dll

Install rust using rustup. For development the normal stable toolchain is enough. For building a x86 dll the stable-i686 toolchain is needed. (install with rustup install stable-i686).

Run cargo build --release for x64 dll or cargo +stable-i686 build --release for x86 systems.

The built dll can be found in here ./target/release/middleware_wrapper_atrust.dll.

Note: To get a smaller dll the library can be compiled with the --no-default-features flag. With this flag all of the unimplemented functions will not be included in the final dll.

Contributing

Feel free to open issues about questions you have or bugs you found.

If you find a bug you can solve yourself or have a feature you want to add we also happily accept pull requests.

Development

Use the rust-analyzer extension for visual studio code for IDE features.

Tests

Run cargo test --all-features. Add -- --nocapture to the command to see stdout and stderr.

To run the tests on a real fiskaltrust.SCU set the SCU_URL environment variable to the SCU REST endpoint (e.g. http://localhost:1401/scu_url).

License

This project is licensed under the MIT License - see the LICENSE file for details