Environment Variables

This document describes all environment variables used by the CLI tools and the mini-eric-php SDK.

ceric CLI Environment Variables

The ceric CLI tool uses the following environment variables:

Variable
Default
Description

APP_ENV

staging

Application environment (affects test flag behavior)

CERTIFICATE_PIN

123456

PIN for certificate access

DEVELOPER_ID

00000

Five digits developer ID provided by ELSTER

DEVELOPER_NAME

Test

Developer name to identify the developer of the software which communicates with ELSTER

PATH_CERTIFICATE

bin/eric/test-softorg-pse.pfx

Path to certificate file for send/transmit operations

PATH_VENDOR

bin/eric/plugins

Path to the ERiC vendor libraries directory

cotto CLI Environment Variables

The cotto CLI tool uses the following environment variables:

Variable
Default
Description

DEVELOPER_ID

00000

Five digits developer ID provided by ELSTER

PATH_CERTIFICATE

bin/eric/test-softorg-pse.pfx

Path to certificate file for download operation

CERTIFICATE_PIN

123456

PIN for certificate access

Detailed Descriptions

APP_ENV

  • Purpose: Application environment identifier

  • Default: staging

  • Usage: Affects behavior of test flags and processing logic

  • Special Values:

    • production: Disables test flags

    • Other values: Uses test flags for communication with ELSTER servers

  • Example: export APP_ENV="production"

CERTIFICATE_PIN

  • Purpose: PIN for accessing the certificate file

  • Default: 123456

  • Usage: Used to unlock the certificate for authentication and signing processes

  • Example: export CERTIFICATE_PIN="your_secure_pin"

DEVELOPER_ID

  • Purpose: Developer identifier for ERiC processing

  • Default: 00000

  • Usage: Used in ERiC API calls to identify the developer

  • Example: export DEVELOPER_ID="12345"

DEVELOPER_NAME

  • Purpose: Developer name for ERiC processing

  • Default: Test

  • Usage: Used in ERiC API calls

  • Example: export DEVELOPER_NAME="Your Company Name"

PATH_CERTIFICATE

  • Purpose: Path to the certificate file used for send/transmit operations

  • Default: bin/eric/test-softorg-pse.pfx

  • Usage: Required for operations that need to authenticate with ERiC services

  • Example: export PATH_CERTIFICATE="/path/to/your/certificate.pfx"

PATH_VENDOR

  • Purpose: Specifies the location of ERiC vendor plugins

  • Default: bin/eric/plugins

  • Usage: The ceric binary looks for loadable ERiC shared libraries (e.g., *.{dll,dylib,so}) in this directory

  • Example: export PATH_VENDOR="/path/to/eric/plugins"

mini-eric-php SDK Environment Variables

The mini-eric-php SDK automatically sets the following environment variable when executing ceric commands:

Variable
Description

PATH_VENDOR

Vendor path for ERiC plugins

SDK Behavior

The PHP SDK automatically configures the PATH_VENDOR environment variable when running ceric commands. This ensures that the ceric binary can find the required ERiC libraries.

The SDK constructs the path as: {vendor_path}/eric-plugins/

Setting Environment Variables

Linux/macOS

Windows

Docker

Troubleshooting

Common Issues

  1. Certificate not found

    • Verify the file exists and is readable

    • Check that PATH_CERTIFICATE points to a valid certificate file

  2. Library not found

    • Ensure PATH_VENDOR points to the correct ERiC libraries directory

    • Check that required shared libraries are present

  3. Authentication failures

    • Verify CERTIFICATE_PIN is correct

    • Ensure the certificate is valid and not expired

Verification Commands

Security Considerations

  • Never commit certificate files or PINs to version control

  • Use secure methods to store sensitive environment variables

  • Consider using environment-specific configuration files

  • Rotate certificates and PINs regularly

Examples

Staging Environment

Production Environment

Last updated