I have to copy files from one network share folder to another (both are
on different remote machines). Server running this asp.net appllication
is not configurable (except web.config), while network forlers requires
passwords.
The ideal solution would allow me to simply write File.Copy (from, to,
true).
I thought of two possibilities: either map a network folder inside the
asp.net application or connect to the server that contail share.
Trying to start 'net use' failed:
System.Diagnost ics.Process.Sta rt ("net", @"use q: \\server\share$
/user:name password");
After this I still have the same drives as before calling 'net use'.
What should I do? How to map a network drive? Or how to access a server
(not changing the machine.config) ? 9 30215
Have you tried using impersonate in the config file to make the application
impersonate a user on the other server, there by giving you permission to
write to the share
"Andrew Shitov" <an**@shitov.ru > wrote in message
news:%2******** ********@TK2MSF TNGP14.phx.gbl. .. I have to copy files from one network share folder to another (both are on different remote machines). Server running this asp.net appllication is not configurable (except web.config), while network forlers requires passwords.
The ideal solution would allow me to simply write File.Copy (from, to, true).
I thought of two possibilities: either map a network folder inside the asp.net application or connect to the server that contail share.
Trying to start 'net use' failed:
System.Diagnost ics.Process.Sta rt ("net", @"use q: \\server\share$ /user:name password");
After this I still have the same drives as before calling 'net use'.
What should I do? How to map a network drive? Or how to access a server (not changing the machine.config) ?
You need to grant asp.net account special rights to run exes. If you can't
change anything on the server, you might want to setup remote machines that
host shared directories to allow access to asp.net account on the web
server.
Eliyahu
"Andrew Shitov" <an**@shitov.ru > wrote in message
news:%2******** ********@TK2MSF TNGP14.phx.gbl. .. I have to copy files from one network share folder to another (both are on different remote machines). Server running this asp.net appllication is not configurable (except web.config), while network forlers requires passwords.
The ideal solution would allow me to simply write File.Copy (from, to, true).
I thought of two possibilities: either map a network folder inside the asp.net application or connect to the server that contail share.
Trying to start 'net use' failed:
System.Diagnost ics.Process.Sta rt ("net", @"use q: \\server\share$ /user:name password");
After this I still have the same drives as before calling 'net use'.
What should I do? How to map a network drive? Or how to access a server (not changing the machine.config) ?
> Have you tried using impersonate in the config file to make the application impersonate a user on the other server, there by giving you permission to write to the share
I inserted <identity impersonate="tr ue"/> into web.config - but I have
to somehow pass userName/password pair. If I will place
userName="..." password="..."
into <identity impersonate/> then an application fails to start.
> You need to grant asp.net account special rights to run exes. If you can't change anything on the server, you might want to setup remote machines that host shared directories to allow access to asp.net account on the web server.
I cannot change remote machine security settings while I am able to
congigure a machine with asp.net application. But is it possible to
aviod modifying machine.config?
How to grant asp.net account these rights?
What you are able to do with your application depends on what rights the
account your application is running under has. Granting rights to accounts
is a job of the system administrator. He/she does it with standard Windows
utilities. It can't be done from within the application.
Eliyahu
"Andrew Shitov" <an**@shitov.ru > wrote in message
news:Oe******** *****@TK2MSFTNG P10.phx.gbl... You need to grant asp.net account special rights to run exes. If you
can't change anything on the server, you might want to setup remote machines
that host shared directories to allow access to asp.net account on the web server.
I cannot change remote machine security settings while I am able to congigure a machine with asp.net application. But is it possible to aviod modifying machine.config?
How to grant asp.net account these rights?
I am able to act as an administrator of a machine with asp.net
application. Would you tell, how to do that? What you are able to do with your application depends on what rights the account your application is running under has. Granting rights to accounts is a job of the system administrator. He/she does it with standard Windows utilities. It can't be done from within the application. How to grant asp.net account these rights?
Here is exactly how i had it working in my application
<configuratio n>
<system.web>
<identity impersonate="tr ue" userName="DMN\U serName"
password="passw ord" />
</system.web>
</configuration>
"Andrew Shitov" <an**@shitov.ru > wrote in message
news:O0******** *****@TK2MSFTNG P10.phx.gbl... Have you tried using impersonate in the config file to make the application impersonate a user on the other server, there by giving you permission to write to the share
I inserted <identity impersonate="tr ue"/> into web.config - but I have to somehow pass userName/password pair. If I will place
userName="..." password="..."
into <identity impersonate/> then an application fails to start.
> <configuratio n> <system.web> <identity impersonate="tr ue" userName="DMN\U serName" password="passw ord" /> </system.web> </configuration>
In this case an application cannot even start:
Parser Error Message: Could not create Windows user token from the
credentials specified in the config file. Error from the operating
system 'Logon failure: unknown user name or bad password. '
An application need these userName/password only to access the remote
server but it tries to use them even when I open an .aspx page.
have you tried to give the user your impersonating, rights to work on the
machine the application is running.
I.E. create a generic user for both servers, enable it admin rights on both
servers, and test if the application will start then?
"Andrew Shitov" <an**@shitov.ru > wrote in message
news:Od******** ******@TK2MSFTN GP12.phx.gbl... <configuratio n> <system.web> <identity impersonate="tr ue" userName="DMN\U serName" password="passw ord" /> </system.web> </configuration>
In this case an application cannot even start:
Parser Error Message: Could not create Windows user token from the credentials specified in the config file. Error from the operating system 'Logon failure: unknown user name or bad password. '
An application need these userName/password only to access the remote server but it tries to use them even when I open an .aspx page. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: James |
last post by:
how can i allow access to a shared network folder? i am trying to give
access to my as pages only. i don't want just anyone to type in the path of
my files. i can't seem to do this with a shared folder.
--
5khzgjf9e001@sneakemail.com
|
by: Mike MacSween |
last post by:
I'm not talking Access Users & Groups, I may or may not implement that. Even
if I do file/folder rights still need to be managed.
I've searched the archives and read the many postings. The basic problem
seems to be this:
Access is a 'file server' based system. So if you want your users to use the
db they've got to have access to the file. And can do stuff to it you might
not want.
|
by: Mike MacSween |
last post by:
Yes, deliberately untrue and provocative subject line. Sorry. Just that I
posted earlier and nobody, apart from Tom, seemed interested.
I'm not talking Jet Users & Groups, I may or may not implement that. Even if
I do file/folder rights still need to be managed.
I've searched the archives and read the many postings. The basic problem
seems to be this:
Access is a 'file server' based system. So if you want your users to use the
|
by: Scott Nicholson |
last post by:
I've got a site set up that uses a network share as it's home directory.
Simple stuff is working fine.
When I try to put a database in there, though, I run into problems.
I'm using:
dim dbconn,sql,dbcomm
dbconn=New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data
source=" & server.mappath("test.mdb") & ";")
|
by: Microsoft News |
last post by:
I have a web server sitting on computer 1, (QA1). Out on the network on my
main server I have a folder with a zip file in it. All I want is for the
web services that are on the web server to pick up the Zip file and send it
when the web services are called.
However I am getting the following error:
-- Message: System.Web.Services.Protocols.SoapException: Server was unable
to process request. ---> System.ApplicationException:...
| |
by: Josh Rolfe |
last post by:
I have a page in classic asp that accces a network drive, The code is as
follows:
<%
dim fso
dim objFolder
set fso=server.createObject("Scripting.FileSystemObject")
set objFolder=fso.GetFolder("f:\")
for each objFile in objFolder.files
response.write objFile.name & "<br>"
next
|
by: JonnyD |
last post by:
I am working on a project to build a reporting web app from an exsiting
database that is controled by a local application. The application that
has control over the database creates a lock file to the database and
at that point I can no longer access the database with my web app. Is
there anyway around this? All I need is read only access to the
database to get some report information to display on the web page.
The error I get on the...
|
by: Jeremy S. |
last post by:
We're in the process of writing a new Windows Forms app and the desktop
support folks want for it to be run from a network share. I know it's
possible (i.e., just have the framework on the clients and a desktop
shortcut to the exe out on the network)... but is it really a good idea?
What are some arguments for and against running a .NET Windows Forms client
from a network share? Here is my initial list... I'd appreciate any
additions,...
|
by: Elton Cohen |
last post by:
Hi newsgroup!
Can anyone tell me where I should put a simple Access database file in
order to be accessible for every computer in the network (same
workgroup)? There does not need to be any protection (I heard people say
that I should buy a dedicated server or have special rights for each and
every user, but I can keep it simple since there will be no intruders -
no internet connection available -).
I don't think that the "Programs"...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |