Skip to content

i18n logging does not check write permission exists #3011

@eschoeller

Description

@eschoeller

Performing upgrade, I get these errors:

Warning: file_put_contents(/share/i18n.log): failed to open stream: Permission denied in /cacti/cacti-1.2.7a-prod/include/global_languages.php on line 756

Warning: file_put_contents(/share/i18n.log): failed to open stream: Permission denied in /cacti/cacti-1.2.7a-prod/include/global_languages.php on line 756

Warning: file_put_contents(/share/i18n.log): failed to open stream: Permission denied in /cacti/cacti-1.2.7a-prod/include/global_languages.php on line 756

Warning: Cannot modify header information - headers already sent by (output started at /cacti/cacti-1.2.7a-prod/include/global_languages.php:756) in /cacti/cacti-1.2.7a-prod/include/auth.php on line 109

The global_languages.php is looking for the existence of /share but not checking to make sure it's writable. I don't know why I have /share, but its being managed on my system by automount, so I can't remove it or change its permissions.
I hacked around this for now so it would write the log file to /tmp/ as that is the alternative location in the code.

Metadata

Metadata

Assignees

Labels

bugUndesired behaviourresolvedA fixed issue

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions