Skip to content

Repository files navigation

http://forwhoallvglhpsx6dhycfb4fu4a2lqkvxtwlivruw765qxofyns7wqd.onion/

https://aera23.net/ (back, no JS needed on Tor, but JS needed to solve Cloudflare's anti DDoS)

https://pastebin.com/DzV4AFQn (PM replies fixed with ClaudeAI, edited from https://github.com/Aera23/-/commit/d6bba788ca789d21a613321f12679651b3251ad5 )

SETUP

  • rename --main.zip to main.zip if you want to extract the zip file (from github's green download button)
  • git clone https://github.com/Aera23/-;mv - w;cd w;php -S 0.0.0.0:1100 -t $(pwd)
  • Use http://127.0.0.1:1100/setup.php (or setup.php in the directory) to change chat secrets.
  • if you extracted zip, move.php can put the page into the server home directory

Chat and stopwatch

  • Included are the chat script, PHP stopwatch and the CAPTCHA.
  • The chat has a typing indicator, if JS is used.
  • (note that disabling js and using the chat would work, only autofocus, vibrate on mobile, and typing indicator will stop)
  • The stopwatch counts time since it was first run in time2.txt

Latency test

  • To run the test, access colour.php
  • To view more data, add ?r=1 (or 2,3,4) when accessing data.php (shows from last day), or download [1-31]l.txt

Comment form

  • Type a comment, and press enter (this was made for people who want to see how simple PHP can be, and because I liked some CSS)
  • The comments are stored in "comments.txt", and can technically be edited (or specific comments can be removed, manually)

File upload

  • This needs sqlite
  • I made it with a lot of ChatGPT assistance
  • I added the timestamps column in DB, and timestamp support
  • I changed chatGPT's dotpoint list to a table, and improved styling
  • ?delete=accesskey to be able to delete files via the upload page (please change $ad at the top of the script)

Installation

  • Copy the files into the directory you want to.
  • Run setup.php then use mod link
  • Optional: Check out stopwatch.php or colour.php :) Enjoy :)

Configuration

  • Characters per second - Controls how fast a user can send messages, validated by server timestamps. Lower is stricter, values below a certain point would block all messages due to captcha expiry or backwards-in-time impossibilities. (If a user sends a 100 character message in 20 seconds, they sent it at 5 characters a second)
  • Message max length - Prevents overly long messages from being sent (and is checked before characters per second).
  • Max messages in a row - Helps prevents a stream of messages from flooding chat. Example, if it's set to 4, and it sees more than 4 messages from a user when checking the last 5/6 messages, it will block messages exceeding that threshold.
  • Two Function system - odd numbers allow users to add emoji, and add/edit/remove string replacements. numbers below 3 enable kickfilter (see table in settings menu)
  • Online list (s) - how recent a user has to be active (eg auto refresh) to be marked as online.
  • Last online (max users) - the maximum amount of users to list. Note: If there are more users online than the setting, they won't be included in the count, too high and there could be lag.
  • PSV filter file - The file that has filters, eg "*FILTER_PHONE_NUM|badword|*FILTER_ADDR|*FILTER_SPACED_OUT|*FILTER_3REP", for auto kicking. the * filters in the example refer to my regex filters. I cannot provide an editor inside the chat, because if a mod calls the filter file 28.php, they can delete the chat or tamper with the code.

Extra

If you need to deal with a spammer, typing "/k spammerNick" will help stop @spammerNick from spamming for a while (there's a cool trick used when they are denied) To clean the public chat, delete the 9ud** data file. (change this filename with find and replace) "Max characters per second" is the maximum rate of typing (estimated by comparing loaded time with message process time, and validated with crc32) Eg: at 7 (cps)... a message sent in 5 seconds can have 35 characters max

Hosting

  • If you are using an external hosting, create an account and follow their instructions. Navigate to the www/htdocs/public or similar using their tools and then start installation.
  • If you want to host on your own machine:
  • for Windows try downloading UniformServer on your machine. Start it up, Run Apache, and go to the www directory.
  • for Linux, try "sudo apt install php" and something like "php -S 127.0.0.1:8000 -t '/var/www/'" and also goto /var/www.
  • Then, copy the files from this page there, and type your server's web address. For Uniserver, it's "localhost/g3.php", or for Linux's php, "127.0.0.1:8000/g3.php".
  • Don't forget to enable port forwarding if you don't use onionsites (or follow an online guide if u do)

Troubleshooting

  • If you get an error called "Can't write to disk" when loading the CAPTCHA, check to see if there are write permissions for PHP and the hosting folder.
  • Also check to see if links.php is present, and rename/delete that file... as the script would otherwise try to put CAPTCHA solutions in /home/peplive/Documents/, which only works if that folder exists
  • Finally, SElinux, hard drive failure, inode limit, and more can stop writing. Search online for troubleshooting

About

My chat, CAPTCHA, and stopwatch

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages