(file) Return to PasswordFile.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Security / UserManager

Diff for /pegasus/src/Pegasus/Security/UserManager/PasswordFile.cpp between version 1.28 and 1.29

version 1.28, 2007/06/05 10:11:04 version 1.29, 2007/06/29 17:43:16
Line 57 
Line 57 
 // //
 //////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
  
   
   
 /** /**
     Constructor.     Constructor.
 */ */
Line 81 
Line 79 
     }     }
     catch(const NoSuchFile&)     catch(const NoSuchFile&)
     {     {
         //l10n  
         //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,  
             //"Password file not found : $0.", _passwordFile);  
         //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,  
             //"Creating blank password file.");  
         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,
             "Security.UserManager.PasswordFile.PWD_FILE_NOT_FOUND",             "Security.UserManager.PasswordFile.PWD_FILE_NOT_FOUND",
             "Password file not found : $0.", _passwordFile);             "Password file not found : $0.", _passwordFile);
Line 130 
Line 123 
                 throw CannotRemoveFile(_passwordFile);                 throw CannotRemoveFile(_passwordFile);
             }             }
         }         }
         //l10n  
         //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,  
             //"Trying to use the backup file : $0.", _passwordBackupFile);  
         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,
             "Security.UserManager.PasswordFile.TRYING_TO_BACKUP_FILE",             "Security.UserManager.PasswordFile.TRYING_TO_BACKUP_FILE",
             "Trying to use the backup file : $0.", _passwordBackupFile);             "Trying to use the backup file : $0.", _passwordBackupFile);
         if (Executor::renameFile(         if (Executor::renameFile(
             _passwordBackupFile.getCString(),  _passwordFile.getCString()) != 0)                  _passwordBackupFile.getCString(),
                   _passwordFile.getCString()) != 0)
         {         {
                         //l10n              Logger::put_l(
             //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,                  Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,
             //"Unable to use the backup file : $0.", _passwordBackupFile);  
             Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,  
                 "Security.UserManager.PasswordFile.CANNOT_USE_BACKUP_FILE",                 "Security.UserManager.PasswordFile.CANNOT_USE_BACKUP_FILE",
                 "Unable to use the backup file : $0.", _passwordBackupFile);                 "Unable to use the backup file : $0.", _passwordBackupFile);
             throw CannotRenameFile(_passwordBackupFile);             throw CannotRenameFile(_passwordBackupFile);
         }         }
         //l10n  
         //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,  
             //"Recovered using the backup file : $0.", _passwordBackupFile);  
         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,
             "Security.UserManager.PasswordFile.RECOVERED_USING_BACKUP_FILE",             "Security.UserManager.PasswordFile.RECOVERED_USING_BACKUP_FILE",
             "Recovered using the backup file : $0.", _passwordBackupFile);             "Recovered using the backup file : $0.", _passwordBackupFile);
Line 166 
Line 152 
  
     if (!ifs)     if (!ifs)
     {     {
         //l10n  
         //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,  
             //"Error opening password file : $0.", _passwordFile);  
         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,
             "Security.UserManager.PasswordFile.ERROR_OPENING_PWD_FILE",             "Security.UserManager.PasswordFile.ERROR_OPENING_PWD_FILE",
             "Error opening password file : $0.", _passwordFile);             "Error opening password file : $0.", _passwordFile);
Line 222 
Line 205 
         //         //
         if (*p != COLON)         if (*p != COLON)
         {         {
             //  
             // Did not find Colon, log a message and skip entry             // Did not find Colon, log a message and skip entry
             //l10n              Logger::put_l(
             //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,                  Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,
             //"Error in reading password entry for : $0.", userName);  
             Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,  
                 "Security.UserManager.PasswordFile.ERROR_READING_PWD_ENTRY",                 "Security.UserManager.PasswordFile.ERROR_READING_PWD_ENTRY",
                 "Error in reading password entry for : $0.", userName);                  "Error in reading password entry for : $0.",
                   userName);
             continue;             continue;
         }         }
  
Line 261 
Line 242 
             //             //
             // Duplicate entry for user, ignore the new entry.             // Duplicate entry for user, ignore the new entry.
             //             //
             //l10n              Logger::put_l(
             //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,                  Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,
             //"Duplicate user: $0.", userName);  
             Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::INFORMATION,  
                 "Security.UserManager.PasswordFile.DUPLICATE_USER",                 "Security.UserManager.PasswordFile.DUPLICATE_USER",
                 "Duplicate user: $0.", userName);                 "Duplicate user: $0.", userName);
         }         }
Line 292 
Line 271 
         {         {
             if (Executor::removeFile(_passwordFile.getCString()) != 0)             if (Executor::removeFile(_passwordFile.getCString()) != 0)
             {             {
                         //l10n                  Logger::put_l(
                 //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,                      Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,
                 //"Cannot remove password file : $0.", _passwordFile);  
                 Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,  
                         "Security.UserManager.PasswordFile.CANNOT_REMOVE_PWD_FILE",                         "Security.UserManager.PasswordFile.CANNOT_REMOVE_PWD_FILE",
                         "Cannot remove password file : $0.", _passwordFile);                         "Cannot remove password file : $0.", _passwordFile);
                 throw CannotRemoveFile(_passwordFile);                 throw CannotRemoveFile(_passwordFile);
Line 309 
Line 286 
             if (Executor::renameFile(_passwordFile.getCString(),             if (Executor::renameFile(_passwordFile.getCString(),
                 _passwordBackupFile.getCString()) != 0)                 _passwordBackupFile.getCString()) != 0)
             {             {
                         //l10n                  Logger::put_l(
                 //Logger::put(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,                      Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,
                 //"Cannot rename password file : $0.", _passwordFile);  
                 Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,  
                         "Security.UserManager.PasswordFile.CANNOT_RENAME_PWD_FILE",                         "Security.UserManager.PasswordFile.CANNOT_RENAME_PWD_FILE",
                         "Cannot rename password file : $0.", _passwordFile);                      "Cannot rename password file : $0.",
                       _passwordFile);
                 throw CannotRenameFile(_passwordFile);                 throw CannotRenameFile(_passwordFile);
             }             }
         }         }
Line 348 
Line 324 
     {     {
         if (Executor::removeFile(_passwordBackupFile.getCString()) != 0)         if (Executor::removeFile(_passwordBackupFile.getCString()) != 0)
         {         {
                 //l10n  
             //Logger::put(Logger::ERROR_LOG, System::CIMSERVER,  
             //Logger::SEVERE,  
           //  "Cannot remove backup password file : $0.",  
             //_passwordBackupFile);  
         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,         Logger::put_l(Logger::ERROR_LOG, System::CIMSERVER, Logger::SEVERE,
             "Security.UserManager.PasswordFile.CANNOT_REMOVE_BACKUP_PWD_FILE",                  "Security.UserManager.PasswordFile."
             "Cannot remove backup password file : $0.", _passwordBackupFile);                      "CANNOT_REMOVE_BACKUP_PWD_FILE",
                   "Cannot remove backup password file : $0.",
                   _passwordBackupFile);
             throw CannotRemoveFile(_passwordBackupFile);             throw CannotRemoveFile(_passwordBackupFile);
         }         }
     }     }
Line 363 
Line 336 
 } }
  
 PEGASUS_NAMESPACE_END PEGASUS_NAMESPACE_END
   


Legend:
Removed from v.1.28  
changed lines
  Added in v.1.29

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2