presales question

j92

New member
hi! two quick questions:

1) can a thread be created from CLI , via either mysql or php executable? (lets say, i want to. auto generate some stats or reporting and make them a regular occurring thread)

2) can uploads be screened for nudity and or csam using something like sightengine ?

one way that could be done is forking off a shell command that has them review it by URL, and then running a sql command to delete the media or something like that if it gets flagged by the provider. i also have some existing php code in existing software that might be portable or usable for it.

are there any existing plugins scripts or docs on implementing point 2? like, at a minimum can we invoke a “antivirus” scanner or something where i can append this into the scan?

scanning or banning media uploads is unfortunately a must-have and im not clear on it being a feature of XF itself.

i did see this: https://xenforo.com/community/resources/jazzaaf-xenantivirus.7341/

which has me wondering what theyre hooking into because id just want to basically do that… just with a moderation service.

i guess while im on the subject, are there any hooks that can trigger a scan of post content as well?

all of these points would be solved if i have any way to just watch specific tables and process the text or media inside them (probably.) which is kind of what im doing in existing solution, its awful but it works

i dont need it made for me i just need to know how to trigger my own post processing scripts for a thread, image, or topic i guess?

thanks
 
Last edited:
I can't answer specifics, but I can tell you that XF has an extensive add-on framework which allows it to be customised in just about every way you want, so if you can write your own add-ons, then I think you can likely achieve all these things.

The full developer documentation is here which might answer your questions:

 
I can't answer specifics, but I can tell you that XF has an extensive add-on framework which allows it to be customised in just about every way you want, so if you can write your own add-ons, then I think you can likely achieve all these things.

The full developer documentation is here which might answer your questions:

precisely what i was hoping for. thank you!
 
Regarding (1) I'm not aware of an existing CLI that does that, the XF CLI itself is more concerned with backend admin (installing and so forth). However there is an HTTP API you can use to easily create threads and the can be accessed easily enough to do what you want. I've used it quite a bit since my PHP is rather rusty these days and I prefer writing in other languages.

Regarding (2) I'm sure I've seen a few existing add-ons that look at some of this, but off the top of my head couldn't name any. You might find the rather long thread on the UK's Online Safety Act worth skimming for some discussion of existing tools. There is a system of web hooks in XF that can be used to interact with it if you don't want to write your own add-ons that are directly integrated and fire at various points. You might look to that to trigger scans and so forth. Otherwise a simple add-on to tie into the various 'save' methods and trigger something else wouldn't be overly complicated to write and might be a better route in order to catch both attachment uploads and hot linked images in your scanning. If it were only attachments then you could also use the notify/watch systems in most *NIX OSs to look for new files in the attachments subfolders and trigger a scan off their arrival assuming you can live with things being published then cleaned up.

I have been thinking about doing something similar myself, but have not had time this year to consider it, I was initially thinking of simply writing a very simple add-on that tied into the "save" call for a new post and triggered some scans off the back of that allowing me to do the heavy lifting elsewhere and potentially share that "service" between various other sites I look after. Still one day maybe!

So in short (1) is very trivial and (2) is more than possible with the tools available to extend the core functionality.
 
Back
Top Bottom