#174893 - 2007-03-22 09:05 PM
4.53 osid.udf change?
|
tjcarst
Hey THIS is FUN
Registered: 2003-09-08
Posts: 243
Loc: USA
|
I normally use this code to prevent script execution on a server. Now Terminal Service sessions do not run the logon script for any user.
Is there a way to get this to work as it did in version 4.23? Thanks for any assistance.
if @userid=administrator
$os=osid()
if $os[2]<>'Workstation'
? "Administrator logging onto server, no script execution..."
sleep 2
exit 0
endif
endif
|
|
Top
|
|
|
|
#174894 - 2007-03-22 09:23 PM
Re: 4.53 osid.udf change?
[Re: tjcarst]
|
tjcarst
Hey THIS is FUN
Registered: 2003-09-08
Posts: 243
Loc: USA
|
For all users, this code returns "Administrator logging on, no script execution..."
So, even if the user is not an admin, it is returning it as such and exiting.
$os=osid()
if @userid=administrator
? "Administrator logging on, no script execution..."
sleep 1
exit 0
else
do some stuff
endif
Oops - was using runas and admin on TS for this bit of code. First code still does not run.
Edited by tjcarst (2007-03-22 09:36 PM)
|
|
Top
|
|
|
|
#174914 - 2007-03-23 03:48 PM
Re: 4.53 osid.udf change?
[Re: Les]
|
tjcarst
Hey THIS is FUN
Registered: 2003-09-08
Posts: 243
Loc: USA
|
The script worked with version 4.23 as is but does not with 4.53. I was just wondering if anyone else had run into this.
The OS value returned is Member Server.
|
|
Top
|
|
|
|
#174923 - 2007-03-23 07:09 PM
Re: 4.53 osid.udf change?
[Re: Gargoyle]
|
Glenn Barnas
KiX Supporter
   
Registered: 2003-01-28
Posts: 4401
Loc: New Jersey
|
Here's a similar version I modified to be mostly compatible with OSID. Seems great minds thought alike..
The advantage of this (and OSID) is that it can report on remote systems, which things like Kix macros (@PRODUCTTYPE) can't.
|
|
_________________________
Actually I am a Rocket Scientist!
|
|
Top
|
|
|
|
#175272 - 2007-04-06 11:02 PM
Re: 4.53 osid.udf change?
[Re: Glenn Barnas]
|
tjcarst
Hey THIS is FUN
Registered: 2003-09-08
Posts: 243
Loc: USA
|
Thanks!!!
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 895 anonymous users online.
|
|
|