kereni
9th June 2003, 18:45
Hi,

when a user create a folder the permissions are drwxrwxrwx
but when the user create a file the permissions are -rw-rw---
How to set BAAN users output files with permissions
-rwxrwx---

Note: the /etc/profile set with umask 777.

Kind Regards,
kereni

NPRao
9th June 2003, 20:09
You can set the environment variables, umask etc using - bse_vars.

Refer to the thread - Environment Variables (http://www.baanboard.com/baanboard/showthread.php?s=&threadid=446&highlight=bsevars)

More info-

SOLUTION 77916
Default permissions used by bshell when generate ASCII files on the OS

SITUATION IDENTIFIED IN:
Bshell environment

SITUATION DESCRIPTION:
Default permissions used by bshell code when generate ASCII files on Operating System using Baan device. By default the umask is set to 06 because this value is hard-coded in bshell.

SOLUTION DESCRIPTION:
The value of 06 can be narrowed down by using the environment variable BMASK. The value of BMASK is OR-ed with 06. So it is not possible to set permissions lower than 06 , for example it isn't possible to set BMASK to 02 or 00.

A new environment variable is introduced called: USE_BMASK_AS_ABSOLUTE. When this variable is set to 1, the value of BMASK is not OR-ed with 06 anymore, but used as an absolute umask. So in this way you can obtain an umask like 02 or 00.

Ways to implement:
1) ASCII implementation:
Set up these variables on the .profile from user configuration.
USE_BMASK_AS_ABSOLUTE=1
BMASK=02

2) BW implementation:
Set up these variables on command line from the BW user configuration
-- -set USE_BMASK_AS_ABSOLUTE=1 -set BMASK=02

With this implementation you will obtain the mask "rw- rw- r--" on the Operating System.

LAST MODIFIED ON: 30-11-99

NOTE:
This solution is applicable for UNIX .

COMMENTS: Be very careful in using this functionality. The default setting of 06 in bshell was introduced for good security reasons. Do serious tests after introducing this.

kereni
9th June 2003, 20:12
can i set the umask for all users without the BW configuration command?

where do i have to set that?
what should be set?

thanks,
kereni

NPRao
9th June 2003, 20:33
You can set the umask in - bse_vars file. Please refer to the link/info I have posted.

Whats needs to be set depends on your requirements -

Pat has posted a good link for more info about umask in the thread -

file permission (http://www.baanboard.com/baanboard/showthread.php?s=&threadid=6621&highlight=umask)

umask - get/set file mode creation mask (http://unix.about.com/library/glossary/bldef-cmd-umask.htm)