UserControls:WebRequests2
Messages   Related Types
This message was discovered on ASPFriends.com 'winforms-cs' list.
Responses highlighted in red are from those people who are likely to be able to contribute good, authoratitive information to this discussion. They include Microsoft employees, MVP's and others who IMHO contribute well to these kinds of discussions.

Stephen Rees
To any who are interested.

Can't connect to OleDB or Access via client side ... don't know how to ?
Connection string doesn't take url ?

Don't care really but any help here welcome?

As previously stated the default security only allows access to the same IP,
so straight connections to a SQLServer at a different IP is out.

I am not up on web services yet but I have tested it and it failed getting
data.
But I think they use WebRequest don't they.

So if I can fool a simpler WebRequest into getting data from a resolved
subdomain, then it should work for a web service.

So hopefully one of these might work.

Right, I am about to pay for DNS management on a domain name.

Then I'm going to map a subdomain of it to my SQLServer IP address,
hopefully this will fool the dotNET security settings that the data is
coming from the same origin as the applet.
Else I'll try and fool a web request and then a web service.

Any info here would be welcome.

At the moment I am just going to resolve a sub domain to the IP at my domain
registrar and NOT get my web host to host the domain.
Would it more likely work if I DID get my web host to resolve a subdomain to
my SQLServer after nameing them as nameservers ?

Is any of this going to work I wonder ?

Regards
Steve.
Reply to this message...
 
    
Saurabh Nandu (VIP)
hi,

Well I have too banged my head on this.. and from what little I found
out was OleDb won't work since the assembly runs on client machine .. So
its either Web Services .. or SQLXML ..
or of course you could try connecting to the SQL IP ..

And you are right, that this does not work currently since U would then
require more trust, so that your applet can connect to a new IP ..

Actually .. one thing I can think of with the Web Services approach is
that .. to consume them we use Proxy Classes . there's a way the Default
Web Proxy class address a Web Service. You can try changing the URL in
the proxy class to see if you can fool the system .. but I am not good
at all with this . so I may be wrong !

Also try hosting the Web Service in the same virtual directory there you
host the Controls .

keep us informed !

Regards,
Saurabh Nandu
[Microsoft MVP]
www.MasterCSharp.com
Master C#, the easy way...

-----Original Message-----
From: Stephen Rees [mailto:Click here to reveal e-mail address]
Sent: Saturday, June 15, 2002 9:19 PM
To: winforms-cs
Subject: [winforms-cs] UserControls:WebRequests2
Importance: High
Sensitivity: Confidential

To any who are interested.

Can't connect to OleDB or Access via client side ... don't know how to ?
Connection string doesn't take url ?

Don't care really but any help here welcome?

As previously stated the default security only allows access to the same
IP, so straight connections to a SQLServer at a different IP is out.

I am not up on web services yet but I have tested it and it failed
getting data.
But I think they use WebRequest don't they.

So if I can fool a simpler WebRequest into getting data from a resolved
subdomain, then it should work for a web service.

So hopefully one of these might work.

Right, I am about to pay for DNS management on a domain name.

Then I'm going to map a subdomain of it to my SQLServer IP address,
hopefully this will fool the dotNET security settings that the data is
coming from the same origin as the applet.
Else I'll try and fool a web request and then a web service.

Any info here would be welcome.

At the moment I am just going to resolve a sub domain to the IP at my
domain registrar and NOT get my web host to host the domain.
Would it more likely work if I DID get my web host to resolve a
subdomain to my SQLServer after nameing them as nameservers ?

Is any of this going to work I wonder ?

Regards
Steve.
Reply to this message...
 
    
Stephen Rees
Saurabh ...

Hi, we have spoken before , I wrote to you at your site once.

Ironic, it was your very own bookstock that I converted to applet and tried
connection to the web !

No-one seems to care about applets - I love 'em !

I reckon that they should be used to update web databases because the edit
item template in asp.NET can only deal with one record at a time, after that
you're down to spilling 20 records to a page and updating the lot of them in
one go with some jazzy server code and db id linked html id's !

This is by far the best way to update (or a client app).
The security isn't really an issue because the owners would install the
necessary permissions - but I have a feeling it can be done and it would be
nice to know how.
The client app doesn't need the perms, but isn't always available and the
ability to install the perms isn't always available either.
It would also be nice to do if anyone ever wanted a version of their product
range done like this, so they could shop using the applet ..... and that's
where this could come in handy also.

And good for displaying data via graphs ....

I'm getting sick of the browser, I'd prefer to use apps for anything that
needs a practical approach - like shopping, not that I ever go shopping on
the web (does anyone ???, the only thing I ever buy is domains, hosting and
DNS - does anyone actually buy anything on the web I wonder ?????).

Damn, my card just failed so now I have to wait untill I can check all this
out properly, buggerit.

Steve.

p.s. thanx for the top tips in your email, I'm sure they'll put me on the
right track. :-)
p.p.s. how on earth do you manage to do a economics degree on top of all
this lot ?

-----Original Message-----
From: Saurabh Nandu [mailto:Click here to reveal e-mail address]
Sent: 15 June 2002 17:04
To: winforms-cs
Subject: [winforms-cs] RE: UserControls:WebRequests2
Sensitivity: Confidential

hi,

Well I have too banged my head on this.. and from what little I found out
was OleDb won't work since the assembly runs on client machine .. So its
either Web Services .. or SQLXML ..

or of course you could try connecting to the SQL IP ..

And you are right, that this does not work currently since U would then
require more trust, so that your applet can connect to a new IP ..

Actually .. one thing I can think of with the Web Services approach is
that .. to consume them we use Proxy Classes . there's a way the Default Web
Proxy class address a Web Service. You can try changing the URL in the proxy
class to see if you can fool the system .. but I am not good at all with
this . so I may be wrong !

Also try hosting the Web Service in the same virtual directory there you
host the Controls .

keep us informed !

Regards,

Saurabh Nandu

[Microsoft MVP]

www.MasterCSharp.com

Master C#, the easy way...

-----Original Message-----
From: Stephen Rees [mailto:Click here to reveal e-mail address]
Sent: Saturday, June 15, 2002 9:19 PM
To: winforms-cs
Subject: [winforms-cs] UserControls:WebRequests2
Importance: High
Sensitivity: Confidential

To any who are interested.

Can't connect to OleDB or Access via client side ... don't know how to ?
Connection string doesn't take url ?

Don't care really but any help here welcome?

As previously stated the default security only allows access to the same
IP, so straight connections to a SQLServer at a different IP is out.

I am not up on web services yet but I have tested it and it failed getting
data.

But I think they use WebRequest don't they.

So if I can fool a simpler WebRequest into getting data from a resolved
subdomain, then it should work for a web service.

So hopefully one of these might work.

Right, I am about to pay for DNS management on a domain name.

Then I'm going to map a subdomain of it to my SQLServer IP address,
hopefully this will fool the dotNET security settings that the data is
coming from the same origin as the applet.

Else I'll try and fool a web request and then a web service.

Any info here would be welcome.

At the moment I am just going to resolve a sub domain to the IP at my
domain registrar and NOT get my web host to host the domain.

Would it more likely work if I DID get my web host to resolve a subdomain
to my SQLServer after nameing them as nameservers ?

Is any of this going to work I wonder ?

Regards

Steve.

| [winforms-cs] member Click here to reveal e-mail address = YOUR ID |
http://www.asplists.com/asplists/winforms-cs.asp = JOIN/QUIT
Reply to this message...
 
    
Stephen Rees
Saurabh

I used to send emails from a site using remote scripting in conventional
asp, needless to say I decompiled the applet there to see what was inside
and altered it a bit I think. I always though that it was ironic that remote
scripting in asp was based on java ... sort of sums up conventional asp
really doesn't it.

These web services are basically an extension of that aren't they.
{{ I've also had a look at the SOAP stuff when I was looking at some great
big VB COM object I downloaded from MS. I like this stuff aswell, I don't
know why - I just think it's concept is quite neat.}}

I haven't checked on Remoting - but what's the difference between WebService
and Remoting ?

I don't need a reply to this if your busy as I shall discover for myself
shortly - but a prior, simplified outline is always helpful (saves reading
all that Marsian in the .NET help)

Also - it's not a good idea to put connection string in anything client
side, incl. applet, 'cos decompile.
So whatever happens were going to be using web services (or remoting).
I take it the connection would be handled on the server using these.

Thanx in advance.
Steve.

-----Original Message-----
From: Saurabh Nandu [mailto:Click here to reveal e-mail address]
Sent: 15 June 2002 17:04
To: winforms-cs
Subject: [winforms-cs] RE: UserControls:WebRequests2
Sensitivity: Confidential

hi,

Well I have too banged my head on this.. and from what little I found out
was OleDb won't work since the assembly runs on client machine .. So its
either Web Services .. or SQLXML ..

or of course you could try connecting to the SQL IP ..

And you are right, that this does not work currently since U would then
require more trust, so that your applet can connect to a new IP ..

Actually .. one thing I can think of with the Web Services approach is
that .. to consume them we use Proxy Classes . there's a way the Default Web
Proxy class address a Web Service. You can try changing the URL in the proxy
class to see if you can fool the system .. but I am not good at all with
this . so I may be wrong !

Also try hosting the Web Service in the same virtual directory there you
host the Controls .

keep us informed !

Regards,

Saurabh Nandu

[Microsoft MVP]

www.MasterCSharp.com

Master C#, the easy way...

-----Original Message-----
From: Stephen Rees [mailto:Click here to reveal e-mail address]
Sent: Saturday, June 15, 2002 9:19 PM
To: winforms-cs
Subject: [winforms-cs] UserControls:WebRequests2
Importance: High
Sensitivity: Confidential

To any who are interested.

Can't connect to OleDB or Access via client side ... don't know how to ?
Connection string doesn't take url ?

Don't care really but any help here welcome?

As previously stated the default security only allows access to the same
IP, so straight connections to a SQLServer at a different IP is out.

I am not up on web services yet but I have tested it and it failed getting
data.

But I think they use WebRequest don't they.

So if I can fool a simpler WebRequest into getting data from a resolved
subdomain, then it should work for a web service.

So hopefully one of these might work.

Right, I am about to pay for DNS management on a domain name.

Then I'm going to map a subdomain of it to my SQLServer IP address,
hopefully this will fool the dotNET security settings that the data is
coming from the same origin as the applet.

Else I'll try and fool a web request and then a web service.

Any info here would be welcome.

At the moment I am just going to resolve a sub domain to the IP at my
domain registrar and NOT get my web host to host the domain.

Would it more likely work if I DID get my web host to resolve a subdomain
to my SQLServer after nameing them as nameservers ?

Is any of this going to work I wonder ?

Regards

Steve.

| [winforms-cs] member Click here to reveal e-mail address = YOUR ID |
http://www.asplists.com/asplists/winforms-cs.asp = JOIN/QUIT
Reply to this message...
 
    
Saurabh Nandu (VIP)
hi,

Never knew the bookstore could be stretched so far .. (it was one of the
first application I wrote on .NET PDC version :-) ) . anyways .. once U
finish ur implementation .. would love to see the demo of the code ;)

I too loved the applets features when they were first highlighted during
the beta phases. the Isolated Storage and stuff .. really kool !

But with .NET SP1 .. my dreams were totally shattered, I mean just to
display a simple GUI Windows Form in IE a end-user has to do so many
things, it totally defeats the purpose!
The humorous point I see is that IE can display rich Java applets, but
the same IE can't display .NET Applets in the name of *security* .
Shouldn't this have been considered earlier while designing the .NET
Framework ??
Actually, I have been taking up this issue with many MS Officials I meet
in India. but never got any positive, worthwhile response .

I had during Beta 2 also carried out a similar endeavor, but never
managed to complete the article series .. although I have the full
source code in Beta2 .. if U need it .. let me know. I will send it over
. It uses a Web Service to communicate with the server, of course that
means the app needs *full* trust.

2 parts are here .. not much new information..
[http://www.mastercsharp.com/article.aspx?ArticleID=72&&TopicID=8 ]
[http://www.mastercsharp.com/article.aspx?ArticleID=73&&TopicID=8 ]

As for the economics degree.. well that's what I was supposed to do .
programming was just a *hobby* which grew into a serious career choice
later . I would attribute a part of my success to the .NET wave . and
another part to my internet friend Nanu, who actually introduced me to
.NET!

PS: I would not trust on my advice so much .. I am just 22 ( just 2 yr
programming experience).. and have a lot of mistakes to commit .. so
that later on I can learn from my mistakes ;)

Regards,
Saurabh Nandu
[Microsoft MVP]
www.MasterCSharp.com
Master C#, the easy way...
-----Original Message-----
From: Stephen Rees [mailto:Click here to reveal e-mail address]
Sent: Saturday, June 15, 2002 11:08 PM
To: winforms-cs
Subject: [winforms-cs] RE: UserControls:WebRequests2
Importance: High
Sensitivity: Confidential

Saurabh ...

Hi, we have spoken before , I wrote to you at your site once.

Ironic, it was your very own bookstock that I converted to applet and
tried connection to the web !

No-one seems to care about applets - I love 'em !

I reckon that they should be used to update web databases because the
edit item template in asp.NET can only deal with one record at a time,
after that you're down to spilling 20 records to a page and updating the
lot of them in one go with some jazzy server code and db id linked html
id's !

This is by far the best way to update (or a client app).
The security isn't really an issue because the owners would install the
necessary permissions - but I have a feeling it can be done and it would
be nice to know how.
The client app doesn't need the perms, but isn't always available and
the ability to install the perms isn't always available either.
It would also be nice to do if anyone ever wanted a version of their
product range done like this, so they could shop using the applet .....
and that's where this could come in handy also.

And good for displaying data via graphs ....

I'm getting sick of the browser, I'd prefer to use apps for anything
that needs a practical approach - like shopping, not that I ever go
shopping on the web (does anyone ???, the only thing I ever buy is
domains, hosting and DNS - does anyone actually buy anything on the web
I wonder ?????).

Damn, my card just failed so now I have to wait untill I can check all
this out properly, buggerit.

Steve.

p.s. thanx for the top tips in your email, I'm sure they'll put me on
the right track. :-)
p.p.s. how on earth do you manage to do a economics degree on top of all
this lot ?
Reply to this message...
 
    
Saurabh Nandu (VIP)
hi,
Well there is a significant difference between Remoting and Web Services
. Remoting is more of an API to replace DCOM.. that means it far richer
that Web Services..
Actually the Web Service model run's on a sub-set of Remoting .. so you
can see Remoting as the parent ..

Few unique facts about Remoting
1) They are not dependant on IIS, they could be hosted in IIS ..
but they could be hosted in Windows Services also ..
2) The fundamental difference would be that in Remoting you expose
*objects*, the client gets a native copy of the remote object can calls
methods on it which of course are executed remotely . again a proxy
class kind of technology ..While in Web Services you expose Methods (not
objects..). Since Remoting exposes objects, its much richer in
functionality there can be state-full components .. static methods,
event call backs etc..
3) Remoting uses 2 formatters SOAP and Binary .. and can use HTTP
or TCP to communicate .. SOAP over HTTP would be the ideal to go over
the Web .. But it seems there are some private extensions to the way
SOAP is handled here .. so its not the best way to interoperate with
other platforms ..
4) As a thumb rule, use Remoting within the Intranet (Binary
formatter over TCP) and use Web Services when ever you are reaching out
over the web ..

I guess Remoting too would require full trust . so it would not make a
BIG difference .

Regards,
Saurabh Nandu
[Microsoft MVP]
www.MasterCSharp.com
Master C#, the easy way...
-----Original Message-----
From: Stephen Rees [mailto:Click here to reveal e-mail address]
Sent: Saturday, June 15, 2002 11:44 PM
To: winforms-cs
Subject: [winforms-cs] RE: UserControls:WebRequests2
Importance: High
Sensitivity: Confidential

Saurabh

I used to send emails from a site using remote scripting in conventional
asp, needless to say I decompiled the applet there to see what was
inside and altered it a bit I think. I always though that it was ironic
that remote scripting in asp was based on java ... sort of sums up
conventional asp really doesn't it.

These web services are basically an extension of that aren't they.
{{ I've also had a look at the SOAP stuff when I was looking at some
great big VB COM object I downloaded from MS. I like this stuff aswell,
I don't know why - I just think it's concept is quite neat.}}

I haven't checked on Remoting - but what's the difference between
WebService and Remoting ?

I don't need a reply to this if your busy as I shall discover for myself
shortly - but a prior, simplified outline is always helpful (saves
reading all that Marsian in the .NET help)

Also - it's not a good idea to put connection string in anything client
side, incl. applet, 'cos decompile.
So whatever happens were going to be using web services (or remoting).
I take it the connection would be handled on the server using these.

Thanx in advance.
Steve.
Reply to this message...
 
 
System.Net.WebRequest
System.Web.Services.WebService




Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
 
 Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us - Terms of Use - Privacy Policy - www.dotnet247.com