# open-license-manager/licensecc architecture

> Architecture diagram of the GitHub repository open-license-manager/licensecc, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/open-license-manager/licensecc
- Repository: https://github.com/open-license-manager/licensecc

## Overview

Licensecc is a C++ licensing and copy-protection library, with a companion customer-facing inspector. The principal workflow is an application requesting license verification; the library locates and parses license data, then applies validity, signature, and machine-identity checks and reports events through its API. Hardware identification draws on OS-specific system information, and date verification can use SNTP to detect a clock set back to retain an expired license. The inspector exposes license diagnostics and machine details. Internal flow is based on the excerpts and SOURCE INDEX; several connections to the unread main API implementation remain unverified.

Main entry points: [`src/library/Licensecc.cpp`](https://github.com/open-license-manager/licensecc/blob/develop/src/library/Licensecc.cpp) (License engine), [`src/library/LicenseParser.cpp`](https://github.com/open-license-manager/licensecc/blob/develop/src/library/LicenseParser.cpp) (License parser), [`include/licensecc/licensecc.h`](https://github.com/open-license-manager/licensecc/blob/develop/include/licensecc/licensecc.h) (C/C++ API), [`src/library/hw_identifier/hw_identifier.hpp`](https://github.com/open-license-manager/licensecc/blob/develop/src/library/hw_identifier/hw_identifier.hpp) (Hardware identifier)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api["Application API"]
  node_api["C/C++ API<br/>[licensecc.h]"]
  node_engine["License engine<br/>[Licensecc.cpp]"]
  node_types["Public data types<br/>[datatypes.h]"]
end

subgraph group_licensing["License Processing"]
  node_locator["License locator"]
  node_parser["License parser<br/>[LicenseParser.cpp]"]
  node_ini["INI reader<br/>[SimpleIni.h]"]
  node_limits["License limits"]
  node_signature["Signature verification"]
  node_events["Audit events<br/>[EventRegistry.cpp]"]
end

subgraph group_identity["Machine And Time"]
  node_hw["Hardware identifier<br/>[hw_identifier.hpp]"]
  node_strategies["Identifier strategies"]
  node_environment["Execution environment"]
  node_os["OS information<br/>[os.h]"]
  node_date["Date verification<br/>[date_verifier.cpp]"]
  node_sntp["SNTP client<br/>[sntp.h]"]
end

subgraph group_tools["Diagnostics"]
  node_inspector["License inspector<br/>[inspector.cpp]"]
end

node_application(("Integrating application"))
node_ntp(("NTP server"))

node_application -->|"requests verification"| node_api
node_api -.->|"delegates to"| node_engine
node_engine -.->|"obtains license data"| node_locator
node_locator -.->|"provides raw data"| node_parser
node_parser -->|"parses license data"| node_ini
node_parser -->|"uses raw license data"| node_locator
node_parser -->|"records parse events"| node_events
node_engine -.->|"checks limits"| node_limits
node_engine -.->|"verifies signature"| node_signature
node_engine -.->|"checks machine identity"| node_hw
node_hw -->|"reads environment data"| node_environment
node_hw -.->|"uses strategies"| node_strategies
node_environment -->|"uses platform information"| node_os
node_date -->|"queries reference time"| node_sntp
node_sntp -->|"sends time request"| node_ntp
node_inspector -->|"requests license checks"| node_api
node_inspector -->|"queries system details"| node_os
node_api -->|"uses API structures"| node_types

click node_api "https://github.com/open-license-manager/licensecc/blob/develop/include/licensecc/licensecc.h"
click node_engine "https://github.com/open-license-manager/licensecc/blob/develop/src/library/Licensecc.cpp"
click node_locator "https://github.com/open-license-manager/licensecc/tree/develop/src/library/locate"
click node_parser "https://github.com/open-license-manager/licensecc/blob/develop/src/library/LicenseParser.cpp"
click node_ini "https://github.com/open-license-manager/licensecc/blob/develop/src/library/ini/SimpleIni.h"
click node_limits "https://github.com/open-license-manager/licensecc/tree/develop/src/library/limits"
click node_signature "https://github.com/open-license-manager/licensecc/blob/develop/src/library/os/signature_verifier.hpp"
click node_events "https://github.com/open-license-manager/licensecc/blob/develop/src/library/base/EventRegistry.cpp"
click node_hw "https://github.com/open-license-manager/licensecc/blob/develop/src/library/hw_identifier/hw_identifier.hpp"
click node_strategies "https://github.com/open-license-manager/licensecc/tree/develop/src/library/hw_identifier"
click node_environment "https://github.com/open-license-manager/licensecc/blob/develop/src/library/os/execution_environment_common.cpp"
click node_os "https://github.com/open-license-manager/licensecc/blob/develop/src/library/os/os.h"
click node_date "https://github.com/open-license-manager/licensecc/blob/develop/src/library/limits/date_verifier.cpp"
click node_sntp "https://github.com/open-license-manager/licensecc/blob/develop/src/library/sntp/sntp.h"
click node_inspector "https://github.com/open-license-manager/licensecc/blob/develop/src/inspector/inspector.cpp"
click node_types "https://github.com/open-license-manager/licensecc/blob/develop/include/licensecc/datatypes.h"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_api,node_engine,node_types toneBlue
class node_locator,node_parser,node_ini,node_limits,node_signature,node_events toneAmber
class node_hw,node_strategies,node_environment,node_os,node_date,node_sntp,node_ntp toneMint
class node_inspector toneRose
class node_application toneIndigo
```

## Components

### Application API

- [C/C++ API](https://github.com/open-license-manager/licensecc/blob/develop/include/licensecc/licensecc.h): `include/licensecc/licensecc.h`
- [License engine](https://github.com/open-license-manager/licensecc/blob/develop/src/library/Licensecc.cpp): `src/library/Licensecc.cpp`
- [Public data types](https://github.com/open-license-manager/licensecc/blob/develop/include/licensecc/datatypes.h): `include/licensecc/datatypes.h`

### License Processing

- [License locator](https://github.com/open-license-manager/licensecc/tree/develop/src/library/locate): `src/library/locate`
- [License parser](https://github.com/open-license-manager/licensecc/blob/develop/src/library/LicenseParser.cpp): `src/library/LicenseParser.cpp`
- [INI reader](https://github.com/open-license-manager/licensecc/blob/develop/src/library/ini/SimpleIni.h): `src/library/ini/SimpleIni.h`
- [License limits](https://github.com/open-license-manager/licensecc/tree/develop/src/library/limits): `src/library/limits`
- [Signature verification](https://github.com/open-license-manager/licensecc/blob/develop/src/library/os/signature_verifier.hpp): `src/library/os/signature_verifier.hpp`
- [Audit events](https://github.com/open-license-manager/licensecc/blob/develop/src/library/base/EventRegistry.cpp): `src/library/base/EventRegistry.cpp`

### Machine And Time

- [Hardware identifier](https://github.com/open-license-manager/licensecc/blob/develop/src/library/hw_identifier/hw_identifier.hpp): `src/library/hw_identifier/hw_identifier.hpp`
- [Identifier strategies](https://github.com/open-license-manager/licensecc/tree/develop/src/library/hw_identifier): `src/library/hw_identifier`
- [Execution environment](https://github.com/open-license-manager/licensecc/blob/develop/src/library/os/execution_environment_common.cpp): `src/library/os/execution_environment_common.cpp`
- [OS information](https://github.com/open-license-manager/licensecc/blob/develop/src/library/os/os.h): `src/library/os/os.h`
- [Date verification](https://github.com/open-license-manager/licensecc/blob/develop/src/library/limits/date_verifier.cpp): `src/library/limits/date_verifier.cpp`
- [SNTP client](https://github.com/open-license-manager/licensecc/blob/develop/src/library/sntp/sntp.h): `src/library/sntp/sntp.h`

### Diagnostics

- [License inspector](https://github.com/open-license-manager/licensecc/blob/develop/src/inspector/inspector.cpp): `src/inspector/inspector.cpp`

### Other components

- **Integrating application**
- **NTP server**

## Connections

- Integrating application → C/C++ API: requests verification (evidence: `README.md`)
- C/C++ API → License engine: delegates to
- License engine → License locator: obtains license data
- License locator → License parser: provides raw data (evidence: `src/library/LicenseParser.cpp`)
- License parser → INI reader: parses license data (evidence: `src/library/LicenseParser.cpp`)
- License parser → License locator: uses raw license data (evidence: `src/library/LicenseParser.cpp`)
- License parser → Audit events: records parse events (evidence: `src/library/LicenseParser.cpp`)
- License engine → License limits: checks limits
- License engine → Signature verification: verifies signature
- License engine → Hardware identifier: checks machine identity
- Hardware identifier → Execution environment: reads environment data (evidence: `src/library/hw_identifier/hw_identifier.hpp`)
- Hardware identifier → Identifier strategies: uses strategies (evidence: `src/library/hw_identifier/hw_identifier.cpp`)
- Execution environment → OS information: uses platform information (evidence: `src/library/os/execution_environment_common.cpp`)
- Date verification → SNTP client: queries reference time (evidence: `src/library/limits/date_verifier.cpp`)
- SNTP client → NTP server: sends time request (evidence: `src/library/sntp/sntp.h`)
- License inspector → C/C++ API: requests license checks (evidence: `src/inspector/inspector.cpp`)
- License inspector → OS information: queries system details (evidence: `src/inspector/inspector.cpp`)
- C/C++ API → Public data types: uses API structures (evidence: `include/licensecc/licensecc.h`)
