web-services

Downloading a large file in iOS app

筅森魡賤 提交于 2020-01-02 07:33:15
问题 I'm trying to clean up some existing code that downloads a large file from a server in chunks, checks the checksum on each 50 packets, then stitches them together. I'm having some trouble to see if it's the most efficient way as right now it crashes some time because of memory issues. If I don't have the checksum, it does not seem to crash, but I would prefer if I could check my files first. @property (nonatomic, retain) NSMutableData * ReceivedData; - (void)connectionDidFinishLoading:

How to setup cookieless domain in Lighttpd?

风流意气都作罢 提交于 2020-01-02 07:31:10
问题 I want to setup domain with disabled cookies, to serve static content. 回答1: Don't set a cookie on your domain then. Seriously. That's all you have to do. Just use a subdomain, and make sure you don't hit whatever your scripting solution is (php, python, whatever) anywhere on that domain. Also, make sure you don't have any lighty modules enabled that cause cookie creation (I'm not sure if there are any or not, but best to check). 来源: https://stackoverflow.com/questions/1186987/how-to-setup

SVC WebService works over HTTP, fails over HTTPS

笑着哭i 提交于 2020-01-02 07:08:56
问题 One of my colleagues is having a problem with an AJAX call to a .NET WebService. The call works under HTTP, but the same call is having a problem under HTTPS. The webservice is written in .NET 4.0 with C# on an IIS 7 server. The secure website is at https://sql.data-rx.com/grouppharmdrugsearch/. There is an unsecured version at http://sql.data-rx.com/grouppharmdrugsearch/. There isn't any sensitive information on the page itself. It is embedded (I believe in a frame) on a client's website

SMS gateway for (legally) spoofing SMS messages

谁说我不能喝 提交于 2020-01-02 06:24:10
问题 I'm looking for an SMS gateway to send text messages over an HTTP interface. However, some SMS gateways do not allow to set the sender ID, and those who allow it either require the user to prove that the sender ID is his own mobile phone number, or they manually check each sender ID to prevent SMS Spoofing. For my application, however, I need to be able to set the sender ID as part of the HTTP request. Depending on the number of users, I might have thousands of different sender IDs, and I

How to invoke a Web Service which requires a certificate in C#?

你离开我真会死。 提交于 2020-01-02 05:50:08
问题 I need to communicate with a third party which has a .asmx web service. This web service is using https. I have the required certificate (.pfx). When first trying to add this service using Add Service Reference in Visual Studio, I got an error. I got passed this error by importing the certificate into the Personal store. After I did that, I tried to add the Service Reference again and it works. So now I can create an instance of the web service. Nice. But now I want to invoke the service. And

Ajax jquery call getting NetworkError: 403 Forbidden error in response

女生的网名这么多〃 提交于 2020-01-02 05:43:07
问题 I am using apache tomcat as a web server. I have deployed webservices on tomcat. If i post request through jquery ajax from local file system to tomcat webservice in response i am getting 403 error. If i run the same script from the same container i am getting valid response from the webservice. I am using following code. function callservice() { jQuery.support.cors = true; var mobNo = document.getElementById('mobileNo').value; var acctNo = document.getElementById('accountNo').value; //var id

Hitting Java web service: curl or URLConnection

…衆ロ難τιáo~ 提交于 2020-01-02 05:28:41
问题 I am using a Java server that exposes a RESTful API on the following URL: http://localhost:8080/my-server/ The docs recommend using curl for submitting simple PUT requests (file uploads), and strongly recommend users to use the exact same arguments as provided in the examples. All of the examples look like this: curl -X PUT -f -u admin:password --data-binary @/absolute/path/file/to/upload/file.ext "http://localhost:8080/my-server/file.ext" This server will not work with FTP or any other

calling a java webservice from html page and javascript

时间秒杀一切 提交于 2020-01-02 05:20:33
问题 I'm trying to call a java implemented web service (using the NetBeans IDE) from javascript. I have read a lot about jQuery and AJAX but i cant seem to get a hand on it. suppose my web service WSDL is found at: http://localhost:8080/MICE_Server/MapEditorService?WSDL web method name : sayHello(String name) which returns a string. how would i be able to to this in javascript? thanks in advance for ur help!! 回答1: If you are using JQuery, there is a SOAP client plugin that you might be interested

Java Spring Web Service Client Fault Handling

随声附和 提交于 2020-01-02 05:00:08
问题 I have written a web service client (using Java Spring and JAXB Marshaller) that works with the UPS web service. When I send a valid request everything works well. When I send an invalid request (weight > 150 lbs) then the UPS web service responds with a SOAP Fault. The client application just fails with a org.springframework.oxm.UnmarshallingFailureException: JAXB unmarshalling exception; nested exception is javax.xml.bind.UnmarshalException: unexpected element (uri:"http://schemas.xmlsoap

WCF Callback: Is it interoperable with Java?

夙愿已清 提交于 2020-01-02 04:57:05
问题 Currently I implement all my webservices in the "normal" fashion... that is, I create a WSDL file in Eclipse and then use WSCF.blue (A visual studio extension) to auto-generate the necessary code and it is reply/request. However I was hoping to use callbacks instead, so I can have my services become "push" services. Before I jump into reworking my application, I was wondering about its interoperability. If I use callbacks (WCF), can my Java client still use this? Oh, and I guess I should