473,378 Members | 1,470 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Got 403 error after the first call to a web service

The web service is called by a program running on pocket pc. When to
call the web service, the first call is still ok, but for the second
or later calls, it will throw "403 Forbidden" WebException. When to
test it using the web interface on pocket IE, everything is fine.

Before there was no such problem, it only happened within a week or
so. I suspect it's caused by the server's firewall settings, but how
come the first call is ok? This is quite wired.

Is there anyone who can help or met this problem before?

Aug 13 '07 #1
6 3333
"alho" <xi**********@gmail.comwrote in message
news:11**********************@i13g2000prf.googlegr oups.com...
The web service is called by a program running on pocket pc. When to
call the web service, the first call is still ok, but for the second
or later calls, it will throw "403 Forbidden" WebException. When to
test it using the web interface on pocket IE, everything is fine.

Before there was no such problem, it only happened within a week or
so. I suspect it's caused by the server's firewall settings, but how
come the first call is ok? This is quite wired.

Is there anyone who can help or met this problem before?
Is the second call exactly like the first call?
--
John Saunders [MVP]

Aug 13 '07 #2
On Aug 13, 10:28 pm, "John Saunders [MVP]" <john.saunders at
trizetto.comwrote:
"alho" <xiaolong....@gmail.comwrote in message

news:11**********************@i13g2000prf.googlegr oups.com...
The web service is called by a program running on pocket pc. When to
call the web service, the first call is still ok, but for the second
or later calls, it will throw "403 Forbidden" WebException. When to
test it using the web interface on pocket IE, everything is fine.
Before there was no such problem, it only happened within a week or
so. I suspect it's caused by the server's firewall settings, but how
come the first call is ok? This is quite wired.
Is there anyone who can help or met this problem before?

Is the second call exactly like the first call?
--
John Saunders [MVP]
Yes, first I got this error at the second call, later when I test it,
I repeated the first call twice in a try catch, and the second line
got this exception too. So the second call always goes wrong no matter
the same or not.

Aug 14 '07 #3
"alho" <xi**********@gmail.comwrote in message
news:11*********************@z24g2000prh.googlegro ups.com...
On Aug 13, 10:28 pm, "John Saunders [MVP]" <john.saunders at
trizetto.comwrote:
>"alho" <xiaolong....@gmail.comwrote in message

news:11**********************@i13g2000prf.googleg roups.com...
The web service is called by a program running on pocket pc. When to
call the web service, the first call is still ok, but for the second
or later calls, it will throw "403 Forbidden" WebException. When to
test it using the web interface on pocket IE, everything is fine.
Before there was no such problem, it only happened within a week or
so. I suspect it's caused by the server's firewall settings, but how
come the first call is ok? This is quite wired.
Is there anyone who can help or met this problem before?

Is the second call exactly like the first call?
--
John Saunders [MVP]

Yes, first I got this error at the second call, later when I test it,
I repeated the first call twice in a try catch, and the second line
got this exception too. So the second call always goes wrong no matter
the same or not.
I would try to determine whether the service itself is getting called, both
the first and second times. In particular, I'd try to find out whether an
exception is being thrown by the service.

The only difference I know about between the first and second calls is that
on the second call, the service is already running. This should not increase
the likelihood of a 403 error. So, I have several questions:

* Is this a normal, ASP.NET "ASMX" web service?
* Is there anything unusual about the service itself, or about the client?
* Does the problem happen when you call the service from two separate
clients, one time apiece? This is to distinguish between a single client
having a problem calling twice, and the service having a problem being
called twice.
* Can you reproduce the problem with a simple "Hello, World" service? This
is to determine whether the issue has to do with the "contents" of the
server, or only with the "structure".
* Can you reproduce the problem with a trivial client? This is to determine
whether the issue is with the client or with the service.

Sorry for all the questions, but this problem doesn't make sense based on
the information given, so I'm looking for more information.
--
John Saunders [MVP]

Aug 14 '07 #4
On Aug 14, 7:37 pm, "John Saunders [MVP]" <john.saunders at
trizetto.comwrote:
"alho" <xiaolong....@gmail.comwrote in message

news:11*********************@z24g2000prh.googlegro ups.com...


On Aug 13, 10:28 pm, "John Saunders [MVP]" <john.saunders at
trizetto.comwrote:
"alho" <xiaolong....@gmail.comwrote in message
>news:11**********************@i13g2000prf.googleg roups.com...
The web service is called by a program running on pocket pc. When to
call the web service, the first call is still ok, but for the second
or later calls, it will throw "403 Forbidden" WebException. When to
test it using the web interface on pocket IE, everything is fine.
Before there was no such problem, it only happened within a week or
so. I suspect it's caused by the server's firewall settings, but how
come the first call is ok? This is quite wired.
Is there anyone who can help or met this problem before?
Is the second call exactly like the first call?
--
John Saunders [MVP]
Yes, first I got this error at the second call, later when I test it,
I repeated the first call twice in a try catch, and the second line
got this exception too. So the second call always goes wrong no matter
the same or not.

I would try to determine whether the service itself is getting called, both
the first and second times. In particular, I'd try to find out whether an
exception is being thrown by the service.

The only difference I know about between the first and second calls is that
on the second call, the service is already running. This should not increase
the likelihood of a 403 error. So, I have several questions:

* Is this a normal, ASP.NET "ASMX" web service?
* Is there anything unusual about the service itself, or about the client?
* Does the problem happen when you call the service from two separate
clients, one time apiece? This is to distinguish between a single client
having a problem calling twice, and the service having a problem being
called twice.
* Can you reproduce the problem with a simple "Hello, World" service? This
is to determine whether the issue has to do with the "contents" of the
server, or only with the "structure".
* Can you reproduce the problem with a trivial client? This is to determine
whether the issue is with the client or with the service.

Sorry for all the questions, but this problem doesn't make sense based on
the information given, so I'm looking for more information.
--
John Saunders [MVP]- Hide quoted text -

- Show quoted text -
Thank you for the attention and the questions.

* It's a normal ASP.NET "ASMX" web service.
* The service itself is fine. Actually before everything was ok. The
client is a PocketPC program.
* It happens in a single client, when calling the service twice.
* It has nothing to do with the content I think, I used complex and
simple web methods to test, got the same result.
* I've done testing using a window application on a PC, it works well
without the problem. But when I did the same testing using a PocketPC
application, the error will occur. The test program is just a textbox
to display result and a button to call a web method. On the PocketPC,
when I click on the button for more than one time, it will throw the
(403) Forbidden exception, but on a PC there is no exception.

This happens on both device and emulator.

Aug 15 '07 #5
"alho" <xi**********@gmail.comwrote in message
news:11**********************@j4g2000prf.googlegro ups.com...
>
Thank you for the attention and the questions.

* It's a normal ASP.NET "ASMX" web service.
* The service itself is fine. Actually before everything was ok. The
client is a PocketPC program.
* It happens in a single client, when calling the service twice.
* It has nothing to do with the content I think, I used complex and
simple web methods to test, got the same result.
* I've done testing using a window application on a PC, it works well
without the problem. But when I did the same testing using a PocketPC
application, the error will occur. The test program is just a textbox
to display result and a button to call a web method. On the PocketPC,
when I click on the button for more than one time, it will throw the
(403) Forbidden exception, but on a PC there is no exception.

This happens on both device and emulator.
Sorry, but I still can't make sense out of this. I hope that you've been
able to solve the problem on your own.
--
--------------------------------------------------------------------------------
John Saunders | MVP - Windows Server System - Connected System Developer

Sep 7 '07 #6
This sounds very similar to a problem I was having. In my case, the
service ALWAYS worked fine on the first call, but never worked the
second time. I too was receiving 403 errors the second time I
submitted the request.

I don't know what version of .Net your have on your desktop, but I
found that I never had problems when the app was run against .Net 1.1,
but I always got the errors when running on .Net 2.0.

With the help of MS tech support, we finally got our issue resolved.
Here is a link to the thread:

http://groups.google.com/group/micro...80c57d255f71/#

Sep 14 '07 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Peter Frost | last post by:
Please help I don't know if this is possible but what I would really like to do is to use On Error Goto to capture the code that is being executed when an error occurs. Any help would be much...
0
by: Nawanat | last post by:
Dear All, I’m developing software using Microsoft Visual C++ 6.0 and having a problem with Remote Procedure Call (RPC). Since RPC is used as a tool to communicate between applications over...
0
by: Francois Guerin | last post by:
I have an application calling a web service on a different machine. The application code runs under a local user account on the application server. The account (identical username/password) is...
4
by: jf li | last post by:
I have a Asp.net web application and a Asp.net Web service application. The Web application is using HtmlInputFile to get a 50M size of file selected by end user, read the data of this file and...
7
by: Jorgen Haukland, Norway | last post by:
Hi, I have created a Java webservice which runs in IBM WebSphere appserver. I take the WSDL-file and create a VS.NET WinForm application and calls the service running on my PC and everything...
10
by: Jim Underwood | last post by:
I am having a problem with my web page timng out while retrieving a long runnign report (90-120 seconds. I have tried modifying several settings in various places and cannot get it to run for more...
4
by: Jason Richmeier | last post by:
I am sure this has been asked at least once before but I could not find anything when searching. If I set the value of the ExitCode property to 1066 for a windows service, the text "A service...
3
by: Lance Wynn | last post by:
Hello, I am receiving this error when trying to instantiate a webservice component. I have 2 development machines, both are XP sp2 with VS 2008 installed. On one machine, the code works fine. On...
0
by: Rod | last post by:
This is my first WCF service and it is running on my development machine (XP Pro SP2) under IIS, I am using wsHttpBinding. (I will eventually put it onto a Windows 2003 Server running under IIS on...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.