It is now possible to integrate your FastSpring store with Cryptolens. This integration allows you to automatically issue licenses to your customers upon a successful payment in your FastSpring store. You can read more on how to get started in the following tutorial.
Not a customer yet? Sign Up for a free trial and implement our software licensing system within minutes.
If you want to implement a software licensing solution in Rust, you have several different ways you can choose between. You can, for example, code a simple license key generator yourself. That can serve as a fun project and is ideal for small-scale use. If you instead want to sell your Rust application, you need a more long-term software licensing solution. Working with a Licensing as a Service (LaaS) provider such as Cryptolens can then save you a lot of time and money. In this blog, we will briefly cover these two alternatives in a bit more detail.
License Key Generator for Rust Applications
A Rust license key generator is a shortcut to software licensing where your application performs partial key verification. You can then generate a subset of license keys that you hand out to select users. We describe this method further in this blog. However, there are several drawbacks to such a simple licensing solution. The structure that you use to generate license keys will leak over time, and it is quite easy to bypass these keygen systems. For more serious and long-term use, it is worth investing in a licensing solution that performs full key verification.
Outsourced Software Licensing Solution in Rust
Instead of having to code a software licensing system yourself, you can work with a Licensing as a Service (LaaS) provider such as Cryptolens to simplify your Rust application’s licensing. Then, you get access to all of our advanced licensing methods from day 1, at a fraction of the price of developing and maintaining such a system yourself.
The steps to get started are easy: We have released a library that you can use to implement full license key verification for applications written in Rust. The library is freely available on GitHub. Then, you can sign up for free to our software licensing platform to manage your license keys, and then insert a short code snippet into your Rust project.
To verify a license, you can use the code similar to the one below. More information about the parameters can be found here.
Autodesk® Revit is a powerful building information software, which allows developers to extend its functionality through plug-ins that can be written in either Python or .NET. In order to monetize your plugin, we need to implement a license verification mechanism and a way to accept payments from prospective customers.
License verification
Python plugins
If your plugin is written in Python, you can use the Python2 version of our Python client. A simple license verification can be performed with the code below (your specific parameters can be found here):
from cryptolens_python2 import *
HelperMethods.ironpython2730_legacy = True
pubKey = "<RSAKeyValue><Modulus>sGbvxwdlDbqFXOMlVUnAF5ew0t0WpPW7rFpI5jHQOFkht/326dvh7t74RYeMpjy357NljouhpTLA3a6idnn4j6c3jmPWBkjZndGsPL4Bqm+fwE48nKpGPjkj4q/yzT4tHXBTyvaBjA8bVoCTnu+LiC4XEaLZRThGzIn5KQXKCigg6tQRy0GXE13XYFVz/x1mjFbT9/7dS8p85n8BuwlY5JvuBIQkKhuCNFfrUxBWyu87CFnXWjIupCD2VO/GbxaCvzrRjLZjAngLCMtZbYBALksqGPgTUN7ZM24XbPWyLtKPaXF2i4XRR9u6eTj5BfnLbKAU5PIVfjIS+vNYYogteQ==</Modulus><Exponent>AQAB</Exponent></RSAKeyValue>"
res = Key.activate(token="WyIyNTU1IiwiRjdZZTB4RmtuTVcrQlNqcSszbmFMMHB3aWFJTlBsWW1Mbm9raVFyRyJd",\
rsa_pub_key=pubKey,\
product_id=3349, key="ICVLD-VVSZR-ZTICT-YKGXL", \
machine_code=Helpers.GetMachineCode())
if res[0] == None or not Helpers.IsOnRightMachine(res[0]):
print("An error occurred: {0}".format(res[1]))
else:
print("Success")
license_key = res[0]
print("Feature 1: " + str(license_key.f1))
print("License expires: " + str(license_key.expires))
C# or VB.NET
If your plugin is either written in C# or VB.NET, you can use our .NET library instead. To add it to your project in Visual Studio:
Right click on your project in the Solution Explorer and click on Manage NuGet Packages.
Add the code-snippet form this page in the code where the plugin loads for the first time.
Accepting payments
One way to sell an Autodesk Revit plug-ins is by publishing them in the Autodesk App Store, where a basic licensing mechanism is already provided. The problem with this approach is that the licensing models available are quite limited (eg. you can only charge your customers once for the plug-in and they will be able to use it in perpetuity). For instance, selling your plug-in as a service (subscription model) is not supported.
A better approach is to still publish your plug-in in the Autodesk App Store and set it to be a free app. You can then ask your customers to get a separate license key to be able to unlock all features.
You can read more about various ways of selling your software in our help pages. I would also recommend to check out the available licensing models.
If you have any questions, please feel free to reach out!
Python can be used to develop a variety of applications, either as plugins (eg. for Discord, AutoCAD, Autodesk Maya, etc) or standalone applications. In this post we will focus on how to monetize a standalone Python application.
Let’s say you have developed a Python application that classifies images (eg. using tensorflow or pytorch). To start selling it, there are just three things we need in place:
Code obfuscation – to ensure that no one can reverse engineer the application.
License verification – to ensure that customers need a license key before they can use the application (eg. so that you can restrict which features they can use and how long the license is valid).
Webshop – so that customers can obtain a license key to unlock functionality.
Code obfuscation
To obfuscate your application, multiple tools can be used. You can either use packages such as pyarmor that are made to obfuscate Python code or open source tools such as pyinstaller in combination with cpython (for most sensitive code).
License verification
A license key can be easily verified using the code below. You can find more information about the parameters here.
from licensing.helpers import Helpers
from licensing.models import Response, RSAPublicKey
from licensing.methods import Key
pubKey = "<RSAKeyValue><Modulus>sGbvxwdlDbqFXOMlVUnAF5ew0t0WpPW7rFpI5jHQOFkht/326dvh7t74RYeMpjy357NljouhpTLA3a6idnn4j6c3jmPWBkjZndGsPL4Bqm+fwE48nKpGPjkj4q/yzT4tHXBTyvaBjA8bVoCTnu+LiC4XEaLZRThGzIn5KQXKCigg6tQRy0GXE13XYFVz/x1mjFbT9/7dS8p85n8BuwlY5JvuBIQkKhuCNFfrUxBWyu87CFnXWjIupCD2VO/GbxaCvzrRjLZjAngLCMtZbYBALksqGPgTUN7ZM24XbPWyLtKPaXF2i4XRR9u6eTj5BfnLbKAU5PIVfjIS+vNYYogteQ==</Modulus><Exponent>AQAB</Exponent></RSAKeyValue>"
res = Key.activate(token="WyIyNTU1IiwiRjdZZTB4RmtuTVcrQlNqcSszbmFMMHB3aWFJTlBsWW1Mbm9raVFyRyJd",\
rsa_pub_key=pubKey,\
product_id=3349, key="ICVLD-VVSZR-ZTICT-YKGXL", machine_code="test")
if res[0] == None:
print("An error occured: {0}".format(res[1]))
else:
print("Success")
Webshop
When you have obfuscation and license verification in place, we need a way for customers to be able to order a license key. If you already have Stripe, you can use the recurring billing module, which acts like an interface for plans defined in your Stripe account. In other cases, you can either use payment forms or a different platform (please read more here).