This concern was just raised on the SQLite Forum (probably
after showing up here). See my reply at
https://sqlite.org/forum/forumpost/8beceed68e for additional
insights into the problem and recent SQLite enhancements to
address it.
Absolutely, there are many things that can be done to mitigate this kind of thing, I'm merely advising caution over people immediately reaching for a solution where they're executing thousands upon thousands of lines of code over untrusted files when they can get away with something much simpler.