user2550943
user2550943

Reputation:

Python script run as root Permission denied

I am configuring tmda on debian 8. I am running tmda-filter.py as root. This script reads a key file. that it insists be CHMOD 400 or 600. The script executes from /package/tmda-fork/tmda/bin/tmda-filter belonging to ROOT:ROOT The key is in /vpopmail/domains/.tmda/crypt_key owned by ROOT:ROOT

Traceback (most recent call last):
File "/package/tmda-fork/tmda/bin/tmda-filter", line 50, in <module>
execfile(os.path.join(execdir, 'tmda-rfilter'))
File "/package/tmda-fork/tmda/bin/tmda-rfilter", line 164, in <module>
from TMDA import Defaults
File "/package/tmda-fork/tmda/TMDA/Defaults.py", line 1753, in       <module>
CRYPT_KEY = binascii.unhexlify(open(CRYPT_KEY_FILE).read().strip())
IOError: [Errno 13] Permission denied:     '/home/vpopmail/domains/mydomain.com/.tmda/crypt_key'

Upvotes: 0

Views: 327

Answers (1)

user2550943
user2550943

Reputation:

Change owners on key file to directory owners and it executed. chown vpopmail:vchkpw

Upvotes: 0

Related Questions