Won't work in the long run. The CP spammer will just look at this regex pattern that you've submitted to vichan publicly and figure out how to bypass it. Like I've already bypassed it in regex101.com just by adding a space in between. Or he'll just put the links in the images like he's done before.
The only ironclad solution is to block all VPNs at the firewall level (e.g. UFW, iptables). This list is accurate and regularly-updated.
https://github.com/X4BNet/lists_vpn/blob/main/output/datacenter/ipv4.txtYou would write a Python script that:
1. Downloads that text file locally (e.g. /opt/vichan/ipv4.txt).
2. If /opt/vichan/ipv4_old.txt exists, add every line to a set variable called "old_ranges" and add every line from ipv4.txt to another set called "new_ranges". Check to see if every range in "old_ranges" exists in "new_ranges", and for those match in "new_ranges" remove it from that set, and for those that don't exist in "new_ranges", add those ranges to a set variable called "to_be_deleted". Add the ranges from "new_ranges" to UFW or iptables via the correct corresponding external commands (subprocess etc.) and delete the ranges from "to_be_deleted" in UFW or iptables via the correct corresponding external commands. Delete ipv4_old.txt and rename ipv4.txt to ipv4_old.txt.
3. If /opt/vichan/ipv4_old.txt does not exist, add all the ranges from ipv4.txt to UFW or iptables via the correct corresponding external commands and then rename ipv4.txt to ipv4_old.txt.
Then you would have this Python script run as a yearly cron job.
I'm sure ChatGPT can do all of this easily within the snap of a finger, but I don't have a VM right now with vichan installed to actually test this (and verify what it does with UFW/iptables, etc.) and I'm too busy to deal with this any time soon.
In the meantime you should add this DNSBL's to your vichan config.php or instance-config.php if you haven't already, these have no false-positives and block Tor effectively.
$config['dnsbl'][] = 'rbl.efnetrbl.org';
$config['dnsbl'][] = 'dnsbl-1.uceprotect.net';
$config['dnsbl'][] = 'dnsbl.dronebl.org';
$config['dnsbl'][] = 'torexit.dan.me.uk';
$config['dnsbl'][] = 'dnsbl.tornevall.org';