What is the hardened runtime?
The hardened runtime is a setting applied when a Mac app is signed. Apple describes it as a way to manage security protections and resource access for your macOS apps. Together with System Integrity Protection, Apple says it protects the runtime integrity of software by preventing certain classes of exploits, such as code injection, dynamically linked library hijacking and process memory space tampering.
Why it matters
Apple says that to upload a macOS app to be notarized, the developer must enable the Hardened Runtime capability. So a notarized app is also a hardened one. Apple says the hardened runtime does not affect most apps, but it disallows some less common capabilities, and a developer can add an entitlement to turn off an individual protection or to allow access that the app needs. Apple advises using only the entitlements that are absolutely necessary.
How NotchStar uses it
NotchStar sets ENABLE_HARDENED_RUNTIME: YES in its project file. NotchStar needs entitlements for camera, calendar and Apple Events access. During development a release script step stripped them. It did no harm while the app was signed ad hoc, but under the hardened runtime that access would have failed without warning. The fix was to sign the framework first, then the app with --entitlements.
Do not confuse it
The hardened runtime is not the App Sandbox. They are separate features that restrict different things.
Related
Read about notarization and is NotchStar safe.