version 1.14, 2006/01/30 16:18:28
|
version 1.15, 2006/01/31 19:15:22
|
|
|
// 2. Set file permission to read/write by the owner only. | // 2. Set file permission to read/write by the owner only. |
// | // |
| |
if ( !FileSystem::changeFilePermissions(filePath, S_IRUSR | S_IWUSR) ) |
#if defined(PEGASUS_OS_TYPE_WINDOWS) |
|
Boolean success = |
|
FileSystem::changeFilePermissions(filePath, _S_IREAD | _S_IWRITE); |
|
#else |
|
Boolean success = |
|
FileSystem::changeFilePermissions(filePath, S_IRUSR | S_IWUSR); |
|
#endif |
|
|
|
if ( !success ) |
{ | { |
String errorMsg = strerror(errno); | String errorMsg = strerror(errno); |
PEG_TRACE_STRING(TRC_AUTHENTICATION, Tracer::LEVEL4, | PEG_TRACE_STRING(TRC_AUTHENTICATION, Tracer::LEVEL4, |
|
|
// | // |
// 4. Set file permission to read only by the owner. | // 4. Set file permission to read only by the owner. |
// | // |
|
#if defined(PEGASUS_OS_TYPE_WINDOWS) |
|
success = |
|
FileSystem::changeFilePermissions(filePath, _S_IREAD); |
|
#else |
|
success = |
|
FileSystem::changeFilePermissions(filePath, S_IRUSR); |
|
#endif |
| |
if ( !FileSystem::changeFilePermissions (filePath, S_IRUSR ) ) |
if ( !success ) |
{ | { |
String errorMsg = strerror(errno); | String errorMsg = strerror(errno); |
PEG_TRACE_STRING(TRC_AUTHENTICATION, Tracer::LEVEL4, | PEG_TRACE_STRING(TRC_AUTHENTICATION, Tracer::LEVEL4, |