Sharada | Posts: 9

Error while creating a package using sandbox api

0 votes
Hi , I'm getting this error only on my TEST server , works fine on my local machine. Could you please advise ? Database Exception Could not create a new package. Exception: Object reference not set to an instance of an object.System.NullReferenceException: Object reference not set to an instance of an object. at Silanis.ESL.SDK.Internal.HttpMethods.PostHttp(String apiToken, String path, Byte[] content) at Silanis.ESL.SDK.RestClient.Post(String path, String jsonPayload) at Silanis.ESL.SDK.Services.PackageService.CreatePackage(Package package) at Silanis.ESL.SDK.Services.PackageService.CreatePackage(Package package) at Silanis.ESL.SDK.EslClient.CreatePackage(DocumentPackage package) Since I'm using 4.5.2 .NET Framework , I even tried adding this to my code , still no use . ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls11 //TLS 1.1 ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12 //TLS 1.2

Duo_Liang | Posts: 3776

Reply to: Error while creating a package using sandbox api

0 votes

Hi Sharada, First, can you try calling this function on your test server:

var appVersion = eslClient.SystemService.GetApplicationVersion();

This is the most basic function we suggest to use testing connection with OneSpan Sign, and if this works, it means your connection (proxy or tls related issue) with OSS is fine. And if this call doesn't success, per this thread, can you try switch your test server to .Net 4.6 and then let's see whether the problem remains. Hope this could help! Duo


Sharada | Posts: 9

Reply to: Error while creating a package using sandbox api

0 votes
Thanks Duo . I was not able to get the Application version successfully , So I'm trying to upgrade my project to .NET 4.6. Still in process , but I will keep you posted.

Sharada | Posts: 9

Reply to: Error while creating a package using sandbox api

0 votes
Hi Duo, I upgraded to 4.6 , but error still persists. Could you please advise ?

Duo_Liang | Posts: 3776

Reply to: Error while creating a package using sandbox api

0 votes
How about the GetApplicationVersion function, can you receive it? And were you receiving the same null pointer error? Because sandbox env was updated to 11.20 this morning with some connection delay, so can you try it again? Duo

Sharada | Posts: 9

Reply to: Error while creating a package using sandbox api

0 votes
No , I did not get any value from that funtion.

Sharada | Posts: 9

Reply to: Error while creating a package using sandbox api

0 votes
Just tried. Works on my local machine , but not on the TEST server. Error : [EslException: Could not create a new package. Exception: Object reference not set to an instance of an object.]

Duo_Liang | Posts: 3776

Reply to: Error while creating a package using sandbox api

0 votes
Hi Sharada, Few more questions, #1. are you using proxy configuration on your Test Server and corresponding setting with your code with SDK? #2. can you use some traffic monitoring tool like fiddler to track your connection with OneSpan Sign to see whether your request was reached out to OSS server? Duo

Sharada | Posts: 9

Reply to: Error while creating a package using sandbox api

0 votes
Made some tweaks and finally getting the value from .GetApplicationVersion() as 16.23.3 .

Duo_Liang | Posts: 3776

Reply to: Error while creating a package using sandbox api

0 votes
So if you use the same eslClient object and create a package, does it make any difference? Duo

Sharada | Posts: 9

Reply to: Error while creating a package using sandbox api

0 votes
If I run locally on the test server , I get the version number, but I call from outside the TEST server , I still get the object reference error.

Hello! Looks like you're enjoying the discussion, but haven't signed up for an account.

When you create an account, we remember exactly what you've read, so you always come right back where you left off