in reply to Can a Perl script modify .htaccess
Yes, it is both dangerous and possible. Apache::Admin::Config and taint mode will help to limit the danger, but only a bit.