Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Calling an executable through a COM+ component via an asp page

Reply
Thread Tools

Calling an executable through a COM+ component via an asp page

 
 
wanaruk@gmail.com
Guest
Posts: n/a
 
      05-21-2008
Hi all.
I am working on a legacy application written in Classic ASP with VB6
COM+ components running on Windows 2003 Adv Server (32bit). There is
one page in the app that uses Secure FTP to send a file to another
application server upon a certain type of data change.

The way it works:
Anonymous user posts the form -> ASP code instantiates the COM+
component which is starting using a Domain User -> Calls a method that
creates the comma delimited data file and then calls the SFTP method -
>


SFTPMethod( )
1. Writes out a script file that connects to the SFTP server, puts the
file in the proper location.

2. Writes a batch file that calls the Tectia SFTP client passing the
script file name as an argument - then archives the file after the
script is executed.

3. Catches the return code from the SFTP client and passes the value
back to the classic ASP page -> in the event of any values besides
zero (Success), we display the error code and message on the page.

The Domain User has permissions to log on as a batch job, and log on
as a service in the Local Security Policy. I have proven the Domain
User has proper permissions to everything because I can log in to the
web server as the Domain User, execute the SFTP client's command line
command passing the app-generated script, and the whole thing works
properly.

Furthermore, when I leave the remote desktop session open for the
domain user account and run it from the web page, everything works.
However, once I log the Domain User out, the transfer fails with the
error 'Failed to connect to server' returned by the sFTP client.

So I know that the COM+ method being run as the Domain User can
generate the data file, generate the script, call the executable, run
the executable, and return the error. The SFTP client just cannot
establish a connection off of the server unless the domain user has an
active windows session on the server. I know I'm missing something
stupid.

We have this working on an old Windows 2000 machine with the exception
that the COM object is being called by a local admin user. But I
can't find where the configuration is different in neither the COM
component or the user's permissions. I've tried using a local admin
account on this Windows 2003 server with the same error.

Any help would be much appreciated.

Thanks
 
Reply With Quote
 
 
 
 
wanaruk@gmail.com
Guest
Posts: n/a
 
      05-21-2008
Hi all. I have solved my own problem but in case anyone else runs
into this:

Running Windows 2003 sp1 with IE7 installled, I had Microsoft's new
DEP (Data Execution Prevention) running. DEP is an anti-malware
measure that keeps bad stuff out of your memory and off of your
network. I had to add my sftp client to the exceptions list. Doing
so allowed me to access stuff off of the server with an unattended
user.

Full description of DEP: http://support.microsoft.com/kb/875352

Thanks for checking.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
using client-side component keeps calling component's init Jim Hammond ASP .Net 1 11-12-2003 08:13 PM
Calling a COM component via C#(ASP .net) Badrinath Mohan ASP .Net Web Services 2 11-12-2003 05:33 PM
Calling a COM component via C#(ASP .net) Badrinath Mohan ASP .Net Security 2 11-12-2003 05:33 PM
Calling a COM component via C#(ASP .net) Badrinath Mohan ASP .Net 2 11-12-2003 05:33 PM
Re: Calling a .NET component from a COM component remotely Soni ASP .Net 0 07-25-2003 04:33 AM



Advertisments