Hello,

I tried to undef all the associated objects before using them - with no 
success.
I don't think, that a bad property is associated with to $PermObject, 
because it works on many objects !
I have displayed the properties of the $PermObject object, and here is the 
result:

dir:\\BILBO\D$\Testing\User\adelheid.schattmaier\ --> works fine !
dir:\\BILBO\D$\Testing\User\alexander.vesely\ --> works fine !
dir:\\BILBO\D$\Testing\User\andreas.freff\ --> works fine !
dir:\\BILBO\D$\Testing\User\anita.staufert\ --> crashes !

The referenced user accounts exist, I'm not working on a BDC or PDC, the 
same results when executing the script on a standalone Win2K box.

Any ideas ??

Best regards,

Christian Kirn 
email [EMAIL PROTECTED]
www www.gaxi.de





Dutrieux Yves <[EMAIL PROTECTED]>
09.03.2001 08:40

 
        An:     "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
        Kopie: 
        Thema:  RE: Antwort: RE: Dr.Watson while using Win32::Perms


Memory problem perhaps ?
Can you try to 'undef' $PermDir before the test ?
Perhaps a bad property associated to $PermObject
Display all the $PermObject properties before the test to see if all it's
correct.

Yves.
-----Message d'origine-----
De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Date: jeudi 8 mars 2001 22:19
À: [EMAIL PROTECTED]
Objet: Antwort: RE: Dr.Watson while using Win32::Perms


Hi,



I tried to "slow down" my script - but the errors are the same. But I did 

a little more testing and found out the following:



- the script always at the same point, always when creating the 

permissions for specific users. That means, that I can reproduce the 

behaviour. But I have no idea about the differences of these users !

- the code which crashes is not the part i mentioned in my first posting, 

it is this part:



if ($PermDir = new Win32::Perms( $PermObject ) ) {

...

} else {

....

}



But hey, what's special about this ??



Best regards,



Christian Kirn 

email [EMAIL PROTECTED]

www www.gaxi.de





Perhaps it may due to little time to 'refresh'/'reflect' the changed

permissions.

Have you try with to display permissions after each changes ?



Yves



-----Message d'origine-----

De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]

Date: mercredi 7 mars 2001 21:03

À: [EMAIL PROTECTED]

Objet: Dr.Watson while using Win32::Perms





Hi all,



I encountered the following major problem. I'm using Win32::Perms to set 

permissions on shares and directories.

When I'm executing the following code, the permissions on the shares (code 




not included) are created without any problem. The code for securing the 

directories is absolutetly the same as for the shares. But when I'm 

executing this code (processing a input file with informations about the 

shares / directories), this script randomly crashes with Dr.Watson. I 

found out, that the code , where I'm adding the permissions for the local 

administrators and the group is "the point of the crash". But hey, it 

works fine on 7 or 8 out of 10 directories and there is really nothing 

special about these directories, where the script crashes. These 

directories are created during execution of the script (the result after 

the crash is a newly created and shared directory with the correct 

share-permission, but the directory permissions are left default). The 

point that drives me crazy is that it works with the majority, but crashes 




with others ! I tried this several times, and I can't reproduce the 

behaviour, sometimes it crashes sometimes not...



Here is the code:

...

# define constants for permissions

$MaskAdmin = "FULL";

$MaskAccount = "CHANGE";

$Access = "Allow";

$Flags = "OBJECT_INHERIT_ACE|CONTAINER_INHERIT_ACE";

...

# adjusting access rights on shared directory

# extract admin share for driveletter of share server

# create dir object for permissions

$PermObject = "\\\\$SHARESERVER\\$USERDIRSHARE\\$USERDIRDIR$User\\";

if ($PermDir = new Win32::Perms( $PermObject ) ) {

...

}



# remove all standard ACE's from dir

if ($PermDir->Remove(-1) ) {

...

}

#***************************************************************************

****************************************************

# create ACE's for the local admin group and the local owners group

$PermDir->Add( "$SHARESERVER\\Administrators", eval( uc $MaskAdmin ), 

eval( uc $Access ), eval( uc $Flags ) );

$PermDir->Add( "$DOMAIN\\$User", eval( uc $MaskAccount ), eval( uc 

$Access ), eval( uc $Flags ) );

if ($PermDir->Set() ) {

...

}

#***************************************************************************

*****************************************************

$PermDir->Close();





By the way, I'm using AP 5.0.6 (Build 623), Win32::Perms 0.2000.02.16, 

both on Win2K Prof SP1 and NT 4.0 SP6a Server in a NT domain. My 

permissions are domain admin.

I also have tested these scripts completly local on my Win2K SP1 box (no 

domain, no network..) with the same result. I'm getting the following 

error:



The instruction at "0x77fac8ac" referenced memory at "0x00000000". The 

memory could not be "written".







Best regards,



Christian Kirn 

email [EMAIL PROTECTED]

www www.gaxi.de



_______________________________________________

Perl-Win32-Admin mailing list

[EMAIL PROTECTED]

http://listserv.ActiveState.com/mailman/listinfo/perl-win32-admin







_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-admin



_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-admin

Reply via email to