This folder contains web applications written in C# that show how to use the REST PKI service.
For other languages, please visit the repository root.
To run the samples, you will need an API access token. If you don't have one, register on the REST PKI website and generate a token.
A sample using ASP.NET MVC can be found in the folder MVC.
Steps to execute the sample:
-
Download the project or clone the repository
-
Open the desired project folder -- MVC or one of the other projects (see below)
-
Open the solution file (.sln) on Visual Studio
-
Generate an API access token on the REST PKI website
-
Paste your access token on the file
web.config -
Run the solution. Make sure your system allows automatic Nuget package restore (if it doesn't, manually restore the packages).
A sample using ASP.NET Web Forms can be found in the folder WebForms. The steps to execute the sample are the same as for the default sample.
A sample using the new ASP.NET Core technology can be found in the folder AspNetCore. See the folder's README for more information.
If you use an older version of Visual Studio which cannot open the MVC and the Web Forms sample, use the project for Visual Studio 2008 located in the folder VS2008. The steps to execute the sample are the same as for the default sample.
A sample .NET desktop application using the Windows Presentation Foundation (WPF) technology is available
on the folder WPF. The steps to execute the sample are similar to the default sample, with the
difference that the API access token is located on the file Util.cs.
The samples use the Nuget package Lacuna.RestPki.Client, a library which encapsulates the API calls to REST PKI. It supports .NET Frameworks 3.5, 4.0 and 4.5 as well as .NET Standard 1.3 (for usage on .NET Core, Xamarin, Mono and UWP).