473,320 Members | 1,946 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,320 software developers and data experts.

Runas

Hello,

I work for a company where the server administrators have two login ID's.
One without admin right that we use to log into our workstations and one with
admin rights that we use to for server administration. A co-worker and I put
together an app in VB.Net that lets us click a button to do things that
require admin rights like opening certain applications. We use runas to open
the app with our admin id's and then any option we select opens using the
admin credentials. Everything works fine with the exception of opening a UNC
path.

process.start(explorer, "\\server\share") 'does nothing

process.start("\\server\share") 'will open the UNC path, but not with
the administrative credentials that the app runs under. We are prompted for
credentials and when we enter the id and password that the app runs under the
path is opened no problem.

Has anyone seen this problem before, or have any suggestions?

Thanks!!

Chad
Apr 2 '06 #1
3 3941
Im taking a guess here; but it is possible that when you spawn another
process this way, that the spawned process picks up the current windows
principal not the Runas account used. You would be advised to attempt to
also spawn a Runas for the internet explorer being started.

process.start( "Runas explorer . . . . .

--
( OHM ) - One Handed Man
AKA Terry Burns - http://TrainingOn.net
"Mr. Novice" <Mr******@discussions.microsoft.com> wrote in message
news:08**********************************@microsof t.com...
Hello,

I work for a company where the server administrators have two login ID's.
One without admin right that we use to log into our workstations and one
with
admin rights that we use to for server administration. A co-worker and I
put
together an app in VB.Net that lets us click a button to do things that
require admin rights like opening certain applications. We use runas to
open
the app with our admin id's and then any option we select opens using the
admin credentials. Everything works fine with the exception of opening a
UNC
path.

process.start(explorer, "\\server\share") 'does nothing

process.start("\\server\share") 'will open the UNC path, but not with
the administrative credentials that the app runs under. We are prompted
for
credentials and when we enter the id and password that the app runs under
the
path is opened no problem.

Has anyone seen this problem before, or have any suggestions?

Thanks!!

Chad

Apr 2 '06 #2
Great idea. We tried it and no luck. Any other suggestions?

Chad

"OHM ( One Handed Man )" wrote:
Im taking a guess here; but it is possible that when you spawn another
process this way, that the spawned process picks up the current windows
principal not the Runas account used. You would be advised to attempt to
also spawn a Runas for the internet explorer being started.

process.start( "Runas explorer . . . . .

--
( OHM ) - One Handed Man
AKA Terry Burns - http://TrainingOn.net
"Mr. Novice" <Mr******@discussions.microsoft.com> wrote in message
news:08**********************************@microsof t.com...
Hello,

I work for a company where the server administrators have two login ID's.
One without admin right that we use to log into our workstations and one
with
admin rights that we use to for server administration. A co-worker and I
put
together an app in VB.Net that lets us click a button to do things that
require admin rights like opening certain applications. We use runas to
open
the app with our admin id's and then any option we select opens using the
admin credentials. Everything works fine with the exception of opening a
UNC
path.

process.start(explorer, "\\server\share") 'does nothing

process.start("\\server\share") 'will open the UNC path, but not with
the administrative credentials that the app runs under. We are prompted
for
credentials and when we enter the id and password that the app runs under
the
path is opened no problem.

Has anyone seen this problem before, or have any suggestions?

Thanks!!

Chad


Apr 3 '06 #3
OK, your Security setting in internet explorer will need to be set to
Automatically log you on with the current username and password. Now if this
doesent work, then it means that explorer is looking at the currently logged
on ID when connecting to remote sites rather than using Runas.

Try and take a look TOOLS | INTERNET OPTIONS | SECURITY | CHOOSE YOUR ZONE |
SCROLL DOWN TO USER LOGON SETTINGS

HTH

--
( OHM ) - One Handed Man
AKA Terry Burns - http://TrainingOn.net

"Mr. Novice" <Mr******@discussions.microsoft.com> wrote in message
news:E9**********************************@microsof t.com...
Great idea. We tried it and no luck. Any other suggestions?

Chad

"OHM ( One Handed Man )" wrote:
Im taking a guess here; but it is possible that when you spawn another
process this way, that the spawned process picks up the current windows
principal not the Runas account used. You would be advised to attempt to
also spawn a Runas for the internet explorer being started.

process.start( "Runas explorer . . . . .

--
( OHM ) - One Handed Man
AKA Terry Burns - http://TrainingOn.net
"Mr. Novice" <Mr******@discussions.microsoft.com> wrote in message
news:08**********************************@microsof t.com...
> Hello,
>
> I work for a company where the server administrators have two login
> ID's.
> One without admin right that we use to log into our workstations and
> one
> with
> admin rights that we use to for server administration. A co-worker and
> I
> put
> together an app in VB.Net that lets us click a button to do things that
> require admin rights like opening certain applications. We use runas to
> open
> the app with our admin id's and then any option we select opens using
> the
> admin credentials. Everything works fine with the exception of opening
> a
> UNC
> path.
>
> process.start(explorer, "\\server\share") 'does nothing
>
> process.start("\\server\share") 'will open the UNC path, but not
> with
> the administrative credentials that the app runs under. We are prompted
> for
> credentials and when we enter the id and password that the app runs
> under
> the
> path is opened no problem.
>
> Has anyone seen this problem before, or have any suggestions?
>
> Thanks!!
>
> Chad
>
>


Apr 3 '06 #4

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

Similar topics

0
by: bharkol1 | last post by:
Hi - We have created an application that uses runas to use a single domain application account for file system (DFS) and database access. We have run into very strange compatibility problems...
0
by: Mike Ripplinger | last post by:
I've written a program for a client to run as a screensaver on their public kiosk PCs. When it runs, it kills all open Internet Explorer windows and makes a specified JPG image dance around the...
0
by: Phillip Galey | last post by:
I'm trying to use the Process object to have RUNAS run DOS commands. I have no problem getting the Process object to run DOS commands and return the resulting text back to the program. However,...
2
by: William Oliveri | last post by:
VB6 under Win2K We have a menu app where we launch applications under different profiles for security reasons. The problem that arises is when printing. That is, the default printer is the one...
1
by: MS MVP ??? for VB.NET | last post by:
Dear all, I am trying to get the Process UserName by using System.Enviorment.Username, I have no problem by normal "run" and by "runas". I can get the process Username with correct value....
1
by: abcd | last post by:
I am using Python to create a process on another computer. Both computers are on the same domain with admin privileges. On computer B I have a batch script which starts a python script. From...
1
by: andrewkl | last post by:
hi, I wrote a C program (runas.c) that runs a command as a different user on Solaris 8. The problem I'm having is that the new user's group memberships aren't going into effect. Take the...
5
by: =?Utf-8?B?R3JhbnQ=?= | last post by:
Hi, In a WinForms application, how can you get the identity of the remote credentials used when kicking off the application with RunAs /NetOnly? I can get local Identity information with...
7
hsn
by: hsn | last post by:
hello everyone i am working on a program which will run the cmd. that part is done. in my program in the Vista OS i can run the normal user cmd. what i need to do is to run the admin cmd so i could...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.