OSL Token Verification
OSL Token Verification provides a Unity request manager and a .NET 10 backend starter for checking Google, Facebook, Apple, Steam, and Discord login results outside the game client.
Overview
Use this package when a Unity project has already acquired a provider credential but should not trust the client callback by itself. Google and Apple identity tokens are validated as JWTs; Facebook, Steam, and Discord credentials are checked through their provider service APIs.
Included Components
TokenVerifyManagerfor Unity-side verification requests- A sample scene at
Assets/OSL/TokenVerification/Samples/Scene/DemoScene.unity - A .NET server source archive at
Assets/OSL/TokenVerification/Server_Dotnet_Source.zipin the exported package - Provider-specific endpoints for Google, Facebook, Apple, Steam, and Discord
- Deny-by-default CORS, Development-only Swagger, per-IP rate limiting, request-size and provider-timeout bounds,
/healthz, correlation IDs, structured credential-safe errors, and identity-safe Unity logging
Basic Setup
- Import OSL Token Verification into the Unity project.
- Extract
Server_Dotnet_Source.zipto a local working folder, keep credentials out ofappsettings.json, and configure them through environment variables or a protected provider. - Start the extracted .NET project with
dotnet run. - Open the sample scene, set the
TokenVerifyManagerserver URL, and run a verification request with a valid provider token.
Requirements
- Unity 2021.3 LTS minimum
- Unity 2021.3.45f2 and 6000.3.12f1 tested for package-isolation import and compile
- .NET 10 SDK for the included backend template
- Provider credentials configured only in the extracted server project
The included server is a starter with safer defaults, not a verified production deployment. Configure HTTPS, secret management, monitoring, account linking, session issuance, and project-specific abuse policy for your own environment.