![]() |
VOOZH | about |
dotnet add package Surevelox.OrchardCore.Licensing --version 1.7.0-rc-20230910.6
NuGet\Install-Package Surevelox.OrchardCore.Licensing -Version 1.7.0-rc-20230910.6
<PackageReference Include="Surevelox.OrchardCore.Licensing" Version="1.7.0-rc-20230910.6" />
<PackageVersion Include="Surevelox.OrchardCore.Licensing" Version="1.7.0-rc-20230910.6" />Directory.Packages.props
<PackageReference Include="Surevelox.OrchardCore.Licensing" />Project file
paket add Surevelox.OrchardCore.Licensing --version 1.7.0-rc-20230910.6
#r "nuget: Surevelox.OrchardCore.Licensing, 1.7.0-rc-20230910.6"
#:package Surevelox.OrchardCore.Licensing@1.7.0-rc-20230910.6
#addin nuget:?package=Surevelox.OrchardCore.Licensing&version=1.7.0-rc-20230910.6&prereleaseInstall as a Cake Addin
#tool nuget:?package=Surevelox.OrchardCore.Licensing&version=1.7.0-rc-20230910.6&prereleaseInstall as a Cake Tool
The Licensing module for Orchard Core CMS.
For Orchard Core module consumers
Manage all your module/feature license keys for module orchard core module that you purchased from orchard core module vendor.
For Module vendors
Build your module with license and let your customer use this module to manage their licenses for your module.
Features
Add Surevelox.OrchardCore.Licensing to your Orchard Core Web project
dotnet add package Surevelox.OrchardCore.Licensing
Include in Setup Recipe to enable the feature by default.
"steps": [
{
"name": "feature",
"enable": [
"Surevelox.OrchardCore.Licensing"
]
}
]
ILicenseHandlerImplement CanHandle and Handle method, this method is called when user adds license key in Admin UI.
internal class LicenseHandler : ILicenseHandler
{
public bool CanHandle(string licenseKey)
{
return true;
}
public void Handle(LicenseValidationContext context,
out LicenseStatus? status, out string id, out DateTime? issuedUtc, out DateTime? expiresUtc,
out Dictionary<string, object> policies)
{
var key = context.LicenseKey;
// Add your own logic to see if the license key is belong to your module
// For example using microsoft standard licensing
LicenseManager.CurrentContext = context;
var license = LicenseManager.Validate(typeof(MyLicensedClass));
var canhandle = (license != null);
if (canhandle)
{
// get the license and polices from encrypted license file
status = LicenseStatus.Valid;
// Read from your license
issuedUtc = license.IssuedOn;
// Read from your license
expiredUtc = license.ExpiresOn;
// add your feature list
features = policies["features"];
id = "lic/my-product/" + license.Id;
}
else
{
// If key is unknown to this validator
id = null;
status = null;
createdUtc = null;
expiredUtc = null;
features = new string[] { };
}
}
}
ILicenseHandler in startup services.AddOrchardCms()
.ConfigureServices( svc=>
{
svc.AddScoped<ILicenseHandler, LicenseHandler>();
});
Read the documentation here
See the open issues for a list of proposed features and known issues.
Like the the module? Support us by sponsoring Surevelox @ Github.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net6.0 net6.0 is compatible. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 is compatible. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 was computed. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
This package is not used by any NuGet packages.
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.7.0-rc-20230910.6 | 432 | 9/11/2023 |
| 1.6.0-rc-20230603.1 | 451 | 6/3/2023 |
| 1.6.0-rc-20230427.2 | 285 | 4/27/2023 |
| 1.5.0-rc-20230602.2 | 209 | 6/3/2023 |
| 1.5.0-rc-20230206.3 | 402 | 2/6/2023 |
| 1.5.0-rc-20230120.2 | 278 | 1/20/2023 |
| 1.5.0-rc-20230116.2 | 252 | 1/17/2023 |
| 1.5.0-rc-20221117.6 | 347 | 11/17/2022 |
| 1.4.0-rc-20230602.1 | 224 | 6/3/2023 |
| 1.4.0-rc-20221117.7 | 243 | 11/17/2022 |
| 1.3.0-rc-20230601.1 | 211 | 6/3/2023 |
| 1.3.0-rc-20221117.8 | 243 | 11/17/2022 |
| 1.3.0-rc-20221015.6 | 269 | 10/15/2022 |
| 1.3.0-preview-20220829.2 | 247 | 8/30/2022 |
| 1.3.0-preview-20220820.6 | 271 | 8/21/2022 |
| 1.3.0-preview-20220802.2 | 552 | 8/2/2022 |
| 1.3.0-preview-20220729.2 | 262 | 8/1/2022 |
| 1.3.0-preview-20220721.9 | 305 | 7/21/2022 |
| 1.3.0-preview-20220719.1 | 260 | 7/19/2022 |
| 1.3.0-preview-20220706.2 | 262 | 7/10/2022 |