S2iEvolution.SingpassApi 8.0.132
SingpassApi
Library to use Singpass in the application.
Installation
Usage
// Create a SingpassService
SingpassConfig config = ConfigLoader<SingpassConfig>.LoadConfig("singpass.json");
SingpassService service = new SingpassService(config);
Generate EC keys for jwks.json
These lines generate 1 JWKS with the private and public key pair. Please separate them in different files.
(var priv, var pub) = JWTUtils.CreateJWKPair(JWTUtils.CreateNewECDsa(), "sig");
var jwkEC =JWTUtils.CreateNewJWKSEC([priv,pub]);
string jwkStringEC = JsonConvert.SerializeObject(jwkEC);
Console.WriteLine($"JWKEC: {jwkStringEC}");
Generate EC keys and store them directly in jwks.json
// Create the service with dedicated config
SingpassConfig config = ConfigLoader<SingpassConfig>.LoadConfig("singpass.json");
SingpassService service = new SingpassService(config);
if (service is not null){
// Create sig key
(var priv, var pub) = JWTUtils.CreateJWKPair(
JWTUtils.CreateNewECDsa(),
"sig"
);
// Create enc key
(var privE, var pubE) = JWTUtils.CreateJWKPair(
JWTUtils.CreateNewECDsa(),
"enc"
);
// Create or append the keys to the dedicated files:
// jwks.json for public keys
// jwks.private.json for private keys
// Keys kid are generated to be complient to singpass notation
service.AppendKeyPairToFile(priv, pub, "../Config");
service.AppendKeyPairToFile(privE, pubE, "../Config");
}
Get singpass key set as JWKSEC
The endpoint must be set in the config file first or it will fail.
JWKSEC? jwks = await service.GetSingpassJWKSECAsync();
No packages depend on S2iEvolution.SingpassApi.
.NET 8.0
- Microsoft.AspNetCore.Authentication.JwtBearer (>= 8.0.7)
- Microsoft.AspNetCore.Mvc.NewtonsoftJson (>= 8.0.7)
- Microsoft.Extensions.Logging.Abstractions (>= 8.0.0)
- jose-jwt (>= 5.2.0)
| Version | Downloads | Last updated |
|---|---|---|
| 8.0.138 | 5 | 05/12/2026 |
| 8.0.137 | 5 | 05/07/2026 |
| 8.0.136 | 3 | 05/07/2026 |
| 8.0.135 | 8 | 04/21/2026 |
| 8.0.134 | 3 | 04/21/2026 |
| 8.0.133 | 3 | 04/21/2026 |
| 8.0.132 | 6 | 04/20/2026 |
| 8.0.131 | 7 | 04/14/2026 |
| 8.0.130 | 4 | 04/14/2026 |
| 8.0.129 | 5 | 04/10/2026 |
| 8.0.128 | 5 | 04/09/2026 |
| 8.0.127 | 4 | 04/08/2026 |
| 8.0.126 | 4 | 04/07/2026 |
| 8.0.125 | 4 | 04/07/2026 |
| 8.0.124 | 4 | 04/02/2026 |
| 8.0.123 | 4 | 04/02/2026 |
| 8.0.122 | 4 | 03/31/2026 |
| 8.0.121 | 2 | 03/31/2026 |
| 8.0.120 | 3 | 03/31/2026 |
| 8.0.119 | 3 | 03/31/2026 |
| 8.0.118 | 3 | 03/31/2026 |
| 8.0.117 | 4 | 03/31/2026 |
| 8.0.116 | 3 | 03/30/2026 |
| 8.0.115 | 12 | 03/17/2026 |
| 8.0.114 | 7 | 03/10/2026 |
| 8.0.113 | 5 | 03/10/2026 |
| 8.0.112 | 5 | 03/10/2026 |
| 8.0.111 | 5 | 03/09/2026 |
| 8.0.110 | 5 | 03/09/2026 |
| 8.0.109 | 9 | 02/26/2026 |
| 8.0.108 | 5 | 02/26/2026 |
| 8.0.107 | 6 | 02/26/2026 |
| 8.0.106 | 5 | 02/26/2026 |
| 8.0.105 | 5 | 02/26/2026 |
| 8.0.104 | 7 | 02/24/2026 |
| 8.0.103 | 5 | 02/24/2026 |
| 8.0.102 | 5 | 02/24/2026 |
| 8.0.101 | 5 | 02/24/2026 |
| 8.0.100 | 5 | 02/24/2026 |
| 8.0.99 | 4 | 02/24/2026 |
| 8.0.97 | 19 | 12/22/2025 |
| 8.0.96 | 7 | 12/22/2025 |
| 8.0.95 | 8 | 12/18/2025 |
| 8.0.94 | 7 | 12/18/2025 |
| 8.0.93 | 7 | 12/18/2025 |
| 8.0.92 | 9 | 12/16/2025 |
| 8.0.91 | 12 | 12/08/2025 |
| 8.0.90 | 13 | 11/25/2025 |
| 8.0.89 | 11 | 11/24/2025 |
| 8.0.88 | 10 | 11/21/2025 |
| 8.0.87 | 12 | 11/20/2025 |
| 8.0.86 | 11 | 11/18/2025 |
| 8.0.85 | 7 | 11/18/2025 |
| 8.0.84 | 7 | 11/18/2025 |
| 8.0.83 | 23 | 11/13/2025 |
| 8.0.82 | 8 | 11/13/2025 |
| 8.0.80 | 12 | 11/10/2025 |
| 8.0.79 | 6 | 11/07/2025 |
| 8.0.78 | 8 | 11/07/2025 |
| 8.0.77 | 6 | 11/07/2025 |
| 8.0.76 | 9 | 11/06/2025 |
| 8.0.75 | 9 | 11/06/2025 |
| 8.0.74 | 8 | 11/06/2025 |
| 8.0.73 | 8 | 11/06/2025 |
| 8.0.72 | 7 | 11/06/2025 |
| 8.0.71 | 6 | 11/06/2025 |
| 8.0.69 | 8 | 11/03/2025 |
| 8.0.68 | 8 | 11/03/2025 |
| 8.0.67 | 7 | 11/03/2025 |
| 8.0.66 | 8 | 11/03/2025 |
| 8.0.65 | 12 | 10/28/2025 |
| 8.0.64 | 8 | 10/27/2025 |
| 8.0.63 | 10 | 10/27/2025 |
| 8.0.62 | 8 | 10/27/2025 |
| 8.0.61 | 7 | 10/27/2025 |
| 8.0.60 | 7 | 10/27/2025 |
| 8.0.59 | 7 | 10/27/2025 |
| 8.0.58 | 7 | 10/27/2025 |
| 8.0.57 | 8 | 10/27/2025 |
| 8.0.56 | 8 | 10/27/2025 |
| 8.0.55 | 9 | 10/27/2025 |
| 8.0.54 | 6 | 10/27/2025 |
| 8.0.53 | 8 | 10/27/2025 |
| 8.0.52 | 8 | 10/27/2025 |
| 8.0.51 | 7 | 10/27/2025 |
| 8.0.50 | 8 | 10/27/2025 |
| 8.0.49 | 7 | 10/27/2025 |
| 8.0.48 | 8 | 10/27/2025 |
| 8.0.47 | 7 | 10/24/2025 |
| 8.0.46 | 11 | 10/21/2025 |
| 8.0.45 | 7 | 10/21/2025 |
| 8.0.44 | 7 | 10/21/2025 |
| 8.0.43 | 6 | 10/21/2025 |
| 8.0.42 | 13 | 02/03/2025 |
| 8.0.41 | 11 | 02/03/2025 |
| 8.0.40 | 12 | 02/03/2025 |
| 8.0.39 | 12 | 02/03/2025 |
| 8.0.38 | 13 | 02/03/2025 |
| 8.0.37 | 12 | 02/03/2025 |
| 8.0.36 | 13 | 01/30/2025 |
| 8.0.35 | 12 | 01/30/2025 |
| 8.0.34 | 14 | 01/30/2025 |
| 8.0.33 | 12 | 01/30/2025 |
| 8.0.32 | 12 | 01/30/2025 |
| 8.0.31 | 14 | 01/30/2025 |
| 8.0.30 | 13 | 01/30/2025 |
| 8.0.29 | 13 | 01/30/2025 |
| 8.0.28 | 14 | 01/30/2025 |
| 8.0.27 | 14 | 01/30/2025 |
| 8.0.26 | 15 | 01/30/2025 |
| 8.0.25 | 12 | 01/30/2025 |
| 8.0.24 | 11 | 01/30/2025 |
| 8.0.22 | 13 | 01/30/2025 |
| 8.0.21 | 14 | 01/30/2025 |
| 8.0.20 | 12 | 01/30/2025 |
| 8.0.19 | 13 | 01/30/2025 |
| 8.0.18 | 11 | 01/30/2025 |
| 8.0.17 | 13 | 01/30/2025 |
| 8.0.16 | 13 | 01/28/2025 |
| 8.0.15 | 13 | 01/28/2025 |
| 8.0.14 | 12 | 01/28/2025 |
| 8.0.13 | 12 | 01/28/2025 |
| 8.0.12 | 13 | 01/28/2025 |
| 8.0.11 | 13 | 01/28/2025 |
| 8.0.10 | 13 | 01/28/2025 |
| 8.0.9 | 15 | 01/28/2025 |
| 8.0.8 | 12 | 01/23/2025 |
| 8.0.7 | 13 | 01/23/2025 |
| 8.0.6 | 13 | 01/21/2025 |
| 8.0.5 | 12 | 01/21/2025 |
| 8.0.4 | 12 | 01/21/2025 |
| 8.0.3 | 12 | 01/21/2025 |
| 8.0.2 | 11 | 01/21/2025 |
| 8.0.1 | 12 | 01/21/2025 |
| 8.0.0 | 13 | 01/21/2025 |