What permissions are needed when creating a GMD file/directory?

What permissions are needed when creating a GMD file/directory?

book

Article ID: KB0087525

calendar_today

Updated On:

Products Versions
TIBCO SmartSockets -
Not Applicable -

Description

Resolution:
mkdir is used to create the directory structure if it does not already exist. If any directories are created, their protection is set to be writable by all users. If world-writable directories are a security risk, create the necessary directories ahead of time with the desired permissions. Read and write access to this directory is required for all authorized users. GMD files are created with the same permission as the directory they are stored in; this allows for easier security configuration. You can override the default policy by setting the option ipc_gmd_directory to point to a directory you create with the permissions you need.  Each client process can set its own GMD directory. Here is some sample code which shows how to achieve this:

T_INT4 status;

status = TutSystem("mkdir my_gmd_dir");
if (status != 0) {
  TutOut("ERROR: could not create directory my_gmd_dir: error was %d\n", status);
}

status = TutSystem("chmod u=rwx,g=rwx,o=rx my_gmd_dir");
if (status != 0) {
  TutOut("ERROR: could not change directory permissions: error was %d\n", status);
}

TutCommandParseStr("setopt ipc_gmd_directory my_gmd_dir");

...

Issue/Introduction

What permissions are needed when creating a GMD file/directory?