TCAT-AS-000450 - Tomcat user UMASK must be set to 0027.

Warning! Audit Deprecated

This audit has been deprecated and will be removed in a future update.

View Next Audit Version

Information

For Unix-based systems, umask settings affect file creation permissions. If the permissions are too loose, newly created log files and applications could be accessible to unauthorized users via the file system. Ensure the Tomcat OS user account has the correct file creation permission settings by validating the OS umask settings for the Tomcat user. Setting umask to 0027 gives the Tomcat user full rights, group users r-x permission and all others no access. Tomcat will most likely be running as a systemd service. Locate the systemd service file for Tomcat. The default location for the link to the service file is in /etc/systemd/system folder. The service file name should be indicative of the Tomcat process so tomcat.service is the logical name for the service file and is the name referenced by the STIG.

Solution

From the Tomcat server as a privileged user:

Use a file editor like nano or vi and edit the /etc/systemd/system/tomcat.service file.

Change the 'UMask=' setting to 0027.

UMask =0027

Save the file and restart Tomcat:
sudo systemctl restart tomcat
sudo systemctl daemon-reload

See Also

https://dl.dod.cyber.mil/wp-content/uploads/stigs/zip/U_Apache_Tomcat_Application_Server_9_V2R7_STIG.zip

Item Details

References: CAT|II, CCI|CCI-001499, Rule-ID|SV-222949r879586_rule, STIG-ID|TCAT-AS-000450, STIG-Legacy|SV-111423, STIG-Legacy|V-102481, Vuln-ID|V-222949

Plugin: Unix

Control ID: e7f0330ca260604ebbb8dfbc0318282eac04c789e0e7b2118d628fa8040ecdb3