Subject: | system configuration is used instead of user defined |
If I define my own configuration file, system files are used, which
could be security issue.
Example:
My configuration file is defined as:
my $res = Net::DNS::Resolver->new(config_file => '/my/dns.conf');
These files are read even if I defined my own file:
/etc/resolv.conf
$HOME/.resolv.conf
./.resolv.conf
Last 2 files shouldn't be read by default since it's possible security
issue - user can drop .resolv.conf pointing to malicious dns server.
This issue was found during testing spamassassin with selinux. For
details see:
https://bugzilla.redhat.com/show_bug.cgi?id=628866#c2