Standard_LicenseNotFound
The Standard_LicenseNotFound diagnostic is a C++ exception in Open CASCADE Technology (OCCT) indicating that a requested commercial or proprietary add-on module failed to locate a valid software license.
In Open CASCADE Technology, Standard_LicenseNotFound is a standard exception class that inherits from Standard_LicenseError and ultimately Standard_Failure. While the core OCCT library is free and open-source under the LGPL (with an OCCT-specific exception), the framework retains this exception type for ABI compatibility and to support proprietary third-party modules or official commercial extensions (such as specialized CAD data translators, advanced Boolean operation solvers, or closed-source toolkits). When caught, it means that an integrated closed-source module has actively rejected a requested operation due to a missing, expired, or invalid license key.
The exception is explicitly raised by commercial extensions, typically via the Standard_LicenseNotFound::Raise() method or the Standard_LicenseNotFound_Raise_if macro, when a required license entitlement cannot be validated at runtime. Common scenarios include: initializing a proprietary STEP, IGES, or JT data translator without a floating license server available; invoking a commercial add-on solver where a node-locked license file is missing, expired, or improperly configured; or migrating an application to a new workstation without re-activating hardware-tied licensing for a third-party OCCT plugin.
#include <Standard_Failure.hxx>
#include <Standard_LicenseNotFound.hxx>
#include <iostream>
void invokeCommercialModule() {
// Simulating a failed proprietary license check within an OCCT-based application
bool hasLicense = false;
Standard_LicenseNotFound_Raise_if(!hasLicense, "No valid license found for commercial module X.");
}
int main() {
try {
invokeCommercialModule();
} catch (const Standard_Failure& e) {
std::cerr << "Caught OCCT Exception: " << e.GetMessageString() << std::endl;
return 1;
}
return 0;
}
Resolve the licensing failure for the proprietary module by configuring correct entitlements, or remove the dependency on the commercial add-on if only open-source OCCT features are required.
```C++
#include <Standard_Failure.hxx>
#include <Standard_LicenseNotFound.hxx>
#include <iostream>
// Use standard open-source OCCT functionality instead
void invokeOpenSourceAlternative() {
// Core OCCT operations do not require license checks
std::cout << "Executing open-source geometric operation." << std::endl;
}
int main() {
try {
invokeOpenSourceAlternative();
} catch (const Standard_Failure& e) {
std::cerr << "Caught OCCT Exception: " << e.GetMessageString() << std::endl;
return 1;
}
return 0;
}
```
Open CASCADE Technology OCCT 7.8.0 — Standard_LicenseNotFound.hxx — retrieved 2026-08-11