daxko / passsharp Goto Github PK
View Code? Open in Web Editor NEWAn Apple Wallet Passbook library in C#/.NET
License: MIT License
An Apple Wallet Passbook library in C#/.NET
License: MIT License
I have that last step as being this :
using (var myStream = new MemoryStream())
{
PassWriter.WriteToStream(myPass, myStream,
new X509Certificate2("MyFiles/AppleWWDRCA.cer"),
new X509Certificate2("MyFiles/Certificates.p12", "mypassword"));
}
But I am getting two exceptions :
System.TypeInitializationException
HResult=0x80131534
Message=The type initializer for 'ServiceStack.Text.JsConfig' threw an exception.
Source=ServiceStack.Text
StackTrace:
at ServiceStack.Text.JsConfig.CreateScope(String config, JsConfigScope scope)
at PassSharp.PassWriter.ToJson(Pass pass)
at PassSharp.PassWriter.WriteToStream(Pass pass, Stream stream, X509Certificate2 appleCert, X509Certificate2 passCert)
at PasskitServer.Controllers.PassesController.Get(String PassTypeId, String LoyGUID) in C:\Users\punky\Documents\Visual Studio 2017\Projects\PasskitServer\PasskitServer\Controllers\PassesController1.cs:line 74
at Microsoft.AspNetCore.Mvc.Internal.ControllerActionInvoker.d__12.MoveNext()
Inner Exception 1:
TypeInitializationException: The type initializer for 'ServiceStack.LicenseUtils' threw an exception.
Inner Exception 2:
FileNotFoundException: Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.
Can someone point out what I am doing wrong?
How do you set the secret key? Pass.AuthenticationToken?
I'm trying to use this code, but it says Key not valid for use in specified state
So what am I doing wrong here?
While i was creating a .pkpass file with writetofile() function then there is an exception like System.Security.Cryptography.CryptographicException: 'Keyset does not exist. Can you please help me out.
How do we get the .pfx file? Do we have to convert our .cer apple pass cert?
Unable to parse expirationDate /Date(1487415600000-0000)/ as a date. We expect dates in "W3C date time stamp format", either "Complete date plus hours and minutes" or "Complete date plus hours, minutes and seconds". For example, 1980-05-07T10:30-05:00.
using C# DateTime on the Pass.expirationDate field, if I leave this field out (which I really can't) the pass works fine
Help :) ?!
Hi, In the code
PassWriter.WriteToStream(pass, ms,
new X509Certificate2(certWDRData),
new X509Certificate2(certPassData, Password));
I'm getting an error saying Invalid provider type specified.
So, what am I doing wrong...
when i try to run the demo i got the following error in .tojson function
The type initializer for 'ServiceStack.Text.JsConfig' threw an exception. that he can not find the pass.json
isnt it suppose to be created?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.