Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Licensing

The compiler’s generate, build and reverse actions require a license. The validate action does not, so source validation (and the extension’s IntelliSense) always works.

The license is managed automatically: it’s taken when using the compiler and released when it’s done, with no manual intervention.

License modes

Organization

A license service manages a pool of seats. The compiler:

  • Connects securely to your organization’s license service (identifying the server with Fingerprint, in the project configuration). Host/Port/Fingerprint are handed out by whoever administers that service — see Setting up the license service if that’s you.
  • Each user holds a single seat at a time.
  • If the compiler closes or loses the connection, the seat is released automatically — no one is left holding a license they’re not using.
  • Compatible with Kerberos/Active Directory authentication, to integrate with your existing corporate credentials.

Individual

A signed license file, bound to the machine, validated locally with no network. The default path is:

  • Linux/macOS: ~/.config/warpgate/license.json
  • Windows: %APPDATA%\warpgate\license.json

Another path can be set with File (in @License), --license-file or WARPGATE_LICENSE_FILE.

Configuration

@License block in the .warpcfg

Optional block inside each @Profile (see Project file) — each profile (Dev/UAT/Prod) can have its own license configuration, to consume different licenses or licensing services depending on the environment. Properties are case-insensitive.

@GeneratorConfig {
    @Profile "Prod" {
        @License {
            Host        : "servidor01.dominio.local"
            Port        : 7443
            Fingerprint : "3f2a9c41d87b05e6a1c4f0937be2d5688a1f4c0d29e7b3a65c8d1f0e4b7a9c23"
        }
    }
}

--profile/Default Profile picks which profile (and therefore which @License) to use on each run — see Project: .warproj and .warpcfg.

KeyDescription
HostLicense service host. If present, the mode is organization and File is ignored.
PortService TCP port, 1 to 65535. Default 7443.
FingerprintSHA-256 fingerprint of the service certificate: 64 hexadecimal characters (uppercase and : separators are accepted).
SPNKerberos service name. Default warpgate-license/<host>.
FilePath to the individual license file.

Without Host, the mode is individual.

Flags and environment variables

FlagEnvironment variableEquivalent to
--license-hostWARPGATE_LICENSE_HOSTHost
--license-portWARPGATE_LICENSE_PORTPort
--license-fingerprintWARPGATE_LICENSE_FINGERPRINTFingerprint
--license-spnWARPGATE_LICENSE_SPNSPN
--license-fileWARPGATE_LICENSE_FILEFile

Precedence: flag > environment variable > .warpcfg.

With several @Profile declared, license-status also respects --profile/Default Profile to know which @License to read from — see Project: .warproj and .warpcfg.

Exit codes

CodeMeaning
3No license available. The compiler prints a message with what to do.
4The license was lost mid-run.
130Run interrupted (Ctrl-C/SIGTERM).

Requesting a license

These support actions don’t take a seat and don’t need --source; --project is optional.

warpgate --action license-request --license-id <ID> --license-out request.json

It writes the request file (--license-out is optional; default request.json) and shows the machine identifier. Once you receive the license file, copy it to the default path (or to the one set with File). Installing a new license replaces the previous one: the previous one stops being valid by serial number.

How to get a license (free for now, time-limited)

Warpgate is currently distributed free of charge: Software House issues free individual licenses, valid for 90 days and renewable. This policy may change later, without affecting already-issued licenses.

  1. On the machine where the compiler will run, generate the request:
    warpgate --action license-request --license-id <name or company> --license-out request.json
    
  2. Send to warpgate@softwarehouse.pe:
    • The generated request.json file.
    • The machine identifier the command prints on screen (needed to issue the license).
  3. Software House replies with a signed license.json file, tied to that machine, valid for 90 days.
  4. Copy that file to the default path (or the one set by --license-file/File/WARPGATE_LICENSE_FILE):
    • Linux/macOS: ~/.config/warpgate/license.json
    • Windows: %APPDATA%\warpgate\license.json
  5. Confirm with warpgate --action license-status (it should show the status and the expiry date).

Once the 90 days are up, generate/build/reverse stop working until you renew — repeat this same procedure to get a new license. validate keeps working regardless, even without a license. For a license with seats for several users (organization mode), also write to warpgate@softwarehouse.pe.

To check the current state:

warpgate --action license-status

It shows the mode, the license, the expiration and, in organization mode, the seats in use and available.

License scope

A license covers one product and one major version (for example, the 0.x series). It can be perpetual or have an expiration date.

Development

Development builds accept WARPGATE_LICENSE=off to skip the requirement. Release binaries do not.

CodeSituation
E00284@License Port is 0.
E00285@License Host is not a valid host.
E00286Fingerprint is not a valid SHA-256 fingerprint.
E00287Warning: Host without Fingerprint.
E00288Warning: Host and File together (File is ignored).