Re: Howto: WebService in not Bin folder?

From: Topper (alexander.rodenkov_at_bix.ru)
Date: 12/23/04


Date: Thu, 23 Dec 2004 15:58:52 +0300

Hello, Dan

I've found decision - befor my application starts check and add tags to
"machin.config" every time. It is a simply.

Thanks.

"Dan Rogers" <danro@microsoft.com> wrote in message
news:CBB$E8t5EHA.3512@cpmsftngxa10.phx.gbl...
> Hi Alexander,
>
> Wow. Wow. Holy wow.
>
> I wish I'd known eaarlier that you were not talking about ASP.net web
> services - we could have saved a lot of time.
>
> Since you have developed your own web server and your own web service
> stack, there is very little you can gain, in my opinion, from reading
about
> how IIS hosted web services function and are controlled. Unless you
> duplicated exactly the functionality and design/configuration of ASP.net,
> nothing I can tell you about how to do something with the Microsoft
ASP.net
> implementation would apply to your own private code base.
>
> The best I can tell you is to look at your code, your own designs, and
then
> see if you have provided the kind of control you desire. I can't comment
> on your implementation, or on the cassini example.
>
> I wish you luck,
>
> Dan Rogers
> Microsoft Corporation
> --------------------
> Reply-To: "Topper" <alexander.rodenkov@bix.ru>
> From: "Topper" <alexander.rodenkov@bix.ru>
> References: <#$DjCGe4EHA.2804@TK2MSFTNGP15.phx.gbl>
> <fIg1b6j4EHA.3744@cpmsftngxa10.phx.gbl>
> <e4hSfgo4EHA.2540@TK2MSFTNGP09.phx.gbl>
> <OC8s5Gs4EHA.824@TK2MSFTNGP11.phx.gbl>
> <epFxrW04EHA.1564@TK2MSFTNGP09.phx.gbl>
> <vaakEA74EHA.3440@cpmsftngxa10.phx.gbl>
> Subject: Re: Howto: WebService in not Bin folder?
> Date: Fri, 17 Dec 2004 15:35:50 +0300
> Lines: 144
> Organization: BIX
> X-Priority: 3
> X-MSMail-Priority: Normal
> X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
> Message-ID: <OvSZjTD5EHA.2180@TK2MSFTNGP10.phx.gbl>
> Newsgroups: microsoft.public.dotnet.framework.webservices
> NNTP-Posting-Host: biks.rmt.ru 213.252.119.58
> Path:
>
cpmsftngxa10.phx.gbl!TK2MSFTNGXS01.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTNGP08
> phx.gbl!TK2MSFTNGP10.phx.gbl
> Xref: cpmsftngxa10.phx.gbl
> microsoft.public.dotnet.framework.webservices:8165
> X-Tomcat-NG: microsoft.public.dotnet.framework.webservices
>
> Ok.
> I've develop project for PDA terminals. There're two components - server
> (PC) and PDA-client(s).
> My project is a part of another commertial solution and used as
> internet/intranet solution. But it is not Internet application.
>
> The one of common goals of my project sounds like this:
> (!)Server part must be as a black box ("pandora box") - it must be prevent
> for any changes and customisations 'cause
> it planned to use as a commertial platform for another terminal clients
> development(!).
>
> Compact framework supports only two ways for data exchange between client
> and server (as i know) - one is Messaging (using SOAP/XML messages
exchange
> over HTTP or TCP). The second is webservices. I've choose second 'cause it
> is a simply to use, development, flexible and simply for any
enhancements.
> The first one is hardly scalable and flexible because i must to declare
any
> SOAP/XML request and response (messages) for client and server.
>
> I'd choose WebService technology for my solution.
> But i have one problem - i must not use IIS server (it concerned with
> services of another solution parts - i cann't change its logic) .
> And i've develop my own web server for hosting own WebServices (i've seen
> Cassini Web server sample).
>
> And now i have two problems that i want to solve:
> 1.My WebService and Web Server use the same assemblies (for example,
> core.dll, common.dll etc.) and i have to place its to BIN folder(for
> websercvices) and ROOT (for webServer and HTTP handler like asmx-file ) -
it
> is not good idea, imho.
> 2. Because this solution is for commertial use, i need to prevent it for
any
> cases of customisations( hacking, unlicense usage, etc.). The common way
is
> to prevent any customisations in asmx-files because these files is TEXT
> files and its use inside description of codebehind assemblies. Some"bad
man"
> (hacker, employee, etc.) can write own webservice as mine and path it in
> asmx-file instead mine assemply. In this case he takes access to any
> information that PDA exchanges to Server - it can be security info like
> credit cards info or some private information.
>
> To solving these problems i found in MSDN that i can configure my web
> service using .config file.
> For one i must use <codebase> or <probing> tags in my .config file.
> For second i must create my own IHTTPHandler-class instead asmx-file and
> describe it as handler in .config file using <<httpHandlers> tag.
> But .config file is also TEXT file and it can be customised by somebody
also
> (like asmx file) =((
>
> And i have two questions:
> 1. How can i configure my ASP.NET applications without .config file - only
> using some class or object? Maybe i may to secure .config file or place it
> into some dll-resources?
> 2. How can i change default place for my WebServices (BIN-folder)? (It is
> not primary goal but i'd describe above why i don't want to divide
> WebServer, HTTP-handlers and WebServices dll-files to different folders)
>
> And how can i secure my ASP.NET solution for any LOCAL customisations (any
> text file like .config and asmx files)?
>
> May anybody answer me how?
>
> Alexander.
>
>
> "Dan Rogers" <danro@microsoft.com> wrote in message
> news:vaakEA74EHA.3440@cpmsftngxa10.phx.gbl...
> > Hi Alexander,
> >
> > Could you be clearer about what the problem is? Why is the Bin
directory
> > something you don't like? And what text file is it that you think there
> is
> > an issue for? What is that issue?
> >
> > Dan
> > --------------------
> > Reply-To: "Topper" <alexander.rodenkov@bix.ru>
> > From: "Topper" <alexander.rodenkov@bix.ru>
> > References: <#$DjCGe4EHA.2804@TK2MSFTNGP15.phx.gbl>
> > <fIg1b6j4EHA.3744@cpmsftngxa10.phx.gbl>
> > <e4hSfgo4EHA.2540@TK2MSFTNGP09.phx.gbl>
> > <OC8s5Gs4EHA.824@TK2MSFTNGP11.phx.gbl>
> > Subject: Re: Howto: WebService in not Bin folder?
> > Date: Thu, 16 Dec 2004 11:03:26 +0300
> > Lines: 36
> > Organization: BIX
> > X-Priority: 3
> > X-MSMail-Priority: Normal
> > X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
> > X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
> > Message-ID: <epFxrW04EHA.1564@TK2MSFTNGP09.phx.gbl>
> > Newsgroups: microsoft.public.dotnet.framework.webservices
> > NNTP-Posting-Host: biks.rmt.ru 213.252.119.58
> > Path:
> >
>
cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP09
> > phx.gbl
> > Xref: cpmsftngxa10.phx.gbl
> > microsoft.public.dotnet.framework.webservices:8126
> > X-Tomcat-NG: microsoft.public.dotnet.framework.webservices
> >
> > I'm trying to use webservice business logic only in binary file (dll )
and
> > asmx-file using for it is not good idea.
> >
> >
> > "Mujtaba Syed" <mujtaba@marlabs.com> wrote in message
> > news:OC8s5Gs4EHA.824@TK2MSFTNGP11.phx.gbl...
> > > Hi Topper:
> > >
> > > > ASMX file has definition(assembly name) of my WebService object for
> > > > ASP.NET.
> > > > ASP.NET searching my WebService assembly in bin folder (by default
it
> > > > defined in machine.config file)
> > > > But if i place my WebService dll not in bin folder ASP.NET cann't
> found
> > it
> > > > and error occured.
> > >
> > > If you use Visual Studio .NET, it breaks your web service into two
> parts,
> > a
> > > .ASMX file and a .ASMX.CS file. The .ASMX.CS file is referenced by the
> > > CODEBEHIND attribute in the .ASMX file. Now when you compile your
> project,
> > > the .ASMX.CS (codebehind) is compiled to a .DLL and placed in your BIN
> > > folder under your VROOT. When the ASP.NET runtime is serving an .ASMX
> file
> > > (reference in the URL), it sees the INHERITS attribute and compiles a
> > > temporary class by inheriting the codebehind class from the DLL. So,
> /BIN
> > is
> > > just the default probing path to lookup assemblies. And since you
don't
> > want
> > > to configure alternative probing paths in web.config, you problem can
be
> > > solved by not using a codebehind at all. Put all your code in .ASMX
and
> be
> > > done with!
> > >
> > > Mujtaba.
> > >
> > >
> >
> >
> >
>
>
>



Relevant Pages

  • Re: running winform exe from the web
    ... The folder is set up to be trusted, and I have a winforms application ... open the config file directly in the browser, ... I haven't done anything in particular with the web server or the folder, ... >> I even don't see the MyObject in the GAC directory. ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: Apache Webserver ?
    ... I am running Red hat version ... > get a simple web server up and running to host my domain. ... The popular belief is that the apache configuration file is ... Apache said where the config file is ...
    (alt.os.linux)
  • Re: running winform exe from the web
    ... > The folder is set up to be trusted, and I have a winforms application ... > open the config file directly in the browser, ... > I haven't done anything in particular with the web server or the folder, ... >>> I even don't see the MyObject in the GAC directory. ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • My CGI Scripts Cant find libstdc++.so.5
    ... my web server has gcc 3.3. ... WEB_BASE_DIR which the CGI scripts use. ... So I want to use a non-default crle config file. ...
    (comp.unix.solaris)