I've got a sharepoint webpart that makes a jquery ajax call to a webapi, but when inspecting the call with fiddler i get a error message that says "Session #84: The remote server (srvkbhnws001) presented a certificate that did not validate, due to RemoteCertificateNameMismatch." Now the client calling is on the domain mydomain.local, the webserver that hosts the webapi is on the same domain. Now the traffic has to be over https so there is a certificate installed on the machines but it is issued to *.mydomain.dk. Is the that the root of the problem, and if so...how do I fix it.
Error calling webapi from sharepoint
127 Views Asked by Nicolai Danielsen At
2
There are 2 best solutions below
0
Nicolai Danielsen
On
It turns out, that the mismatch was caused by the way that I called my webservice. I called my webservice with https://[servername]/[servicename]/[api]/[operation]. But I the server name has to have the domain attached in order to satisfy the certicate so when I changed the DNS mapping so that I could call my service with *.domain.dk/[servicename]/[api]/[operation] the problem was solved.
Related Questions in JQUERY
- How to sort these using Javascript or Jquery Most effectively
- Ajax jQuery firing multiple time display event for the same result
- .hover() seems to overwrite .click()
- Check for numeric value with optional commas javascript
- Extending Highmaps Side Effect
- Array appending after each onclick and loop in javascript
- how can i append part of a table based on how many tr it has?
- Play multiple audio files in a slider
- Remove added set of rows
- Access property of an object of type [Model] in JQuery
- AJAX PHP - Reload div after submit
- proengsoft/laravel-jsvalidation ReferenceError: jQuery is not defined
- when a checkbox is checked how to display a different hidden element using javascript
- Get jquery error Uncaught RangeError: Maximum call stack size exceeded
- Removing only the closest thead on table filtering
Related Questions in SSL
- How to Fix TLS CBC Incorrect Padding Abuse Vulnerability on Windows 2003 Server
- SSL: Error parsing the certificate: Ok
- PHP mysqlnd sha256_password plugin "Access denied", user works from cli mysql
- CFNetwork SSLHandshake failed iOS 9
- Java does not accept 2 methods with same name
- Expected Compatibility Issues with upcoming TLS/SSL Cipher Suite update on Azure WebApps?
- python requests SSLError
- Connecting via mutual SSL fails reading incoming changeCipherSpec
- HTTP to HTTPS mapping using proxy servers
- Ruby on Windows XP: How to change directory of SSL certificates
- KeyStore file is not found in jar, although present in jar
- How do I accept a self-signed SSL certificate using iOS 7's NSURLSession
- Chef remote_file from https site with self signed certificate
- Meteor force-ssl on a staging system without ssl cert?
- Use python SSL to download google.com.au page
Related Questions in ASP.NET-WEB-API
- Implement Onfailure in webApi controller
- WebApi: Reading errors
- Why web API return 404 when deploy to IIS
- One Web API calls the other Web APIs
- colon(:) in url causes error in asp.net
- Make a per-web-application object available to Web API and SignalR controllers
- Using Azure MobileServices library with my own LAN WebApi
- redirect to actionResult method from an api
- How to catch postpack result to Web Api
- Exposing webapi to third party
- .net Web Api 2 Owin authentication token expires suddenly and often on IIS 8.5
- Can you use the same token in ADFS for 2 different relying parties?
- Does 'api/SomeEntity/ForOtherEntity/{otherEntityId}' break REST?
- Generic webAPI method based on parameter types of arrays
- Where can I find user identity when using webapi with Windows Authentication on IIS8
Related Questions in SHAREPOINT-2010
- Upload a document to a SharePoint document library (can be via Rest Api/other) using C# & also retrieve the unique id of the document
- Sharepoint alers email deletion from alerts
- Apache Reverse Proxy erases <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
- Can REST-like URLs be passed/recognized in sharepoint 2010?
- Configure SharePoint 2010 UPS with PowerShell
- How to dynamically create Sharepoint ComboBoxes?
- SharePoint 2013 Custom list field iterator not saving values for MultiLine or person columns
- Publicly available InfoPath form connecting to Access db in a restricted location
- Why does my Sharepoint WebPart deploy (nominally), but is still not available for adding to a page/form?
- Does CAML Query has a default RowLimit value?
- SharePoint CSOM
- I am getting a The type or namespace name 'listcolumns' could not be found (are you missing a using directive or an assembly reference?)
- Sharepoint 2010 CMIS Integration
- JQuery Show All Tab - Issue with on click
- jQuery UI API failing to load properly with LABjs
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
OK first thing you need to do is to Export your root cert in to a file.cert.
Wnd+r and type mmc go to certs find your root cert and export it, for the sake of time and space you will be good if you get to this screen:
Now you have to go to Sharepoint central admin:
Click to new to add a new trust:
and this screen will appear:
Upload there your root cert Click and you will be good to go.