2023-11-07 13:04:56 +00:00
|
|
|
<?php
|
|
|
|
class config{
|
|
|
|
// Welcome to the 4get configuration file
|
|
|
|
// When updating your instance, please make sure this file isn't missing
|
|
|
|
// any parameters.
|
|
|
|
|
|
|
|
// 4get version. Please keep this updated
|
2024-02-18 04:22:19 +00:00
|
|
|
const VERSION = 7;
|
2023-11-07 13:04:56 +00:00
|
|
|
|
|
|
|
// Will be shown pretty much everywhere.
|
|
|
|
const SERVER_NAME = "4get";
|
|
|
|
|
|
|
|
// Will be shown in <meta> tag on home page
|
|
|
|
const SERVER_SHORT_DESCRIPTION = "They live in our walls!";
|
|
|
|
|
|
|
|
// Will be shown in server list ping (null for no description)
|
|
|
|
const SERVER_LONG_DESCRIPTION = null;
|
|
|
|
|
|
|
|
// Add your own themes in "static/themes". Set to "Dark" for default theme.
|
|
|
|
// Eg. To use "static/themes/Cream.css", specify "Cream".
|
|
|
|
const DEFAULT_THEME = "Dark";
|
|
|
|
|
|
|
|
// Enable the API?
|
|
|
|
const API_ENABLED = true;
|
|
|
|
|
|
|
|
// Bot protection
|
2024-02-18 04:22:19 +00:00
|
|
|
// 4get.ca has been hit with 500k bot reqs every single day for months
|
2023-11-07 13:04:56 +00:00
|
|
|
// you probably want to enable this if your instance is public...
|
|
|
|
// 0 = disabled
|
2024-02-18 04:22:19 +00:00
|
|
|
// 1 = ask for image captcha (requires imagemagick v6 or higher)
|
2023-11-07 13:04:56 +00:00
|
|
|
// @TODO: 2 = invite only (users needs a pass)
|
|
|
|
const BOT_PROTECTION = 0;
|
|
|
|
|
2024-01-07 00:43:54 +00:00
|
|
|
// Maximal number of searches per captcha key/pass issued. Counter gets
|
|
|
|
// reset on every APCU cache clear (should happen once a day)
|
|
|
|
const MAX_SEARCHES = 100;
|
|
|
|
|
2023-11-07 13:04:56 +00:00
|
|
|
// if BOT_PROTECTION is set to 1, specify the available datasets here
|
|
|
|
// images should be named from 1.png to X.png, and be 100x100 in size
|
|
|
|
// Eg. data/captcha/birds/1.png up to 2263.png
|
|
|
|
const CAPTCHA_DATASET = [
|
|
|
|
// example:
|
2024-01-07 00:46:13 +00:00
|
|
|
// ["birds", 2263],
|
|
|
|
// ["fumo_plushies", 1006],
|
|
|
|
// ["minecraft", 848]
|
2023-11-07 13:04:56 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
// List of domains that point to your servers. Include your tor/i2p
|
|
|
|
// addresses here! Must be a valid URL. Won't affect links placed on
|
|
|
|
// the homepage.
|
|
|
|
const ALT_ADDRESSES = [
|
|
|
|
//"https://4get.alt-tld",
|
|
|
|
//"http://4getwebfrq5zr4sxugk6htxvawqehxtdgjrbcn2oslllcol2vepa23yd.onion"
|
|
|
|
];
|
|
|
|
|
|
|
|
// Known 4get instances. MUST use the https protocol if your instance uses
|
|
|
|
// it. Is used to generate a distributed list of instances.
|
|
|
|
// To appear in the list of an instance, contact the host and if everyone added
|
|
|
|
// eachother your serber should appear everywhere.
|
|
|
|
const INSTANCES = [
|
|
|
|
"https://4get.ca",
|
|
|
|
"https://4get.zzls.xyz",
|
2023-11-27 06:01:56 +00:00
|
|
|
"https://4getus.zzls.xyz",
|
2023-11-07 13:04:56 +00:00
|
|
|
"https://4get.silly.computer",
|
2023-11-27 06:01:56 +00:00
|
|
|
"https://4get.konakona.moe",
|
|
|
|
"https://4get.lvkaszus.pl",
|
|
|
|
"https://4g.ggtyler.dev",
|
|
|
|
"https://4get.perennialte.ch",
|
2024-02-18 04:22:19 +00:00
|
|
|
"https://4get.sijh.net",
|
2023-11-27 06:01:56 +00:00
|
|
|
"https://4get.hbubli.cc",
|
|
|
|
"https://4get.plunked.party",
|
2024-02-18 04:22:19 +00:00
|
|
|
"https://4get.seitan-ayoub.lol",
|
|
|
|
"https://4get.etenie.pl",
|
|
|
|
"https://4get.lunar.icu",
|
|
|
|
"https://4get.dcs0.hu",
|
|
|
|
"https://4get.kizuki.lol",
|
|
|
|
"https://4get.psily.garden",
|
|
|
|
"https://search.milivojevic.in.rs",
|
|
|
|
"https://4get.snine.nl",
|
2024-02-26 02:35:57 +00:00
|
|
|
"https://4get.datura.network",
|
|
|
|
"https://4get.neco.lol"
|
2023-11-07 13:04:56 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
// Default user agent to use for scraper requests. Sometimes ignored to get specific webpages
|
|
|
|
// Changing this might break things.
|
2024-03-20 15:19:27 +00:00
|
|
|
const USER_AGENT = "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:124.0) Gecko/20100101 Firefox/124.0";
|
2023-11-07 13:04:56 +00:00
|
|
|
|
|
|
|
// Proxy pool assignments for each scraper
|
|
|
|
// false = Use server's raw IP
|
|
|
|
// string = will load a proxy list from data/proxies
|
|
|
|
// Eg. "onion" will load data/proxies/onion.txt
|
|
|
|
const PROXY_DDG = false; // duckduckgo
|
|
|
|
const PROXY_BRAVE = false;
|
|
|
|
const PROXY_FB = false; // facebook
|
2024-03-20 15:00:38 +00:00
|
|
|
const PROXY_GOOGLE = false;
|
2023-11-07 13:04:56 +00:00
|
|
|
const PROXY_MARGINALIA = false;
|
|
|
|
const PROXY_MOJEEK = false;
|
|
|
|
const PROXY_SC = false; // soundcloud
|
2024-01-07 00:43:54 +00:00
|
|
|
const PROXY_SPOTIFY = false;
|
2023-11-07 13:04:56 +00:00
|
|
|
const PROXY_WIBY = false;
|
2024-01-07 00:43:54 +00:00
|
|
|
const PROXY_CURLIE = false;
|
2023-11-07 13:04:56 +00:00
|
|
|
const PROXY_YT = false; // youtube
|
|
|
|
const PROXY_YEP = false;
|
|
|
|
const PROXY_PINTEREST = false;
|
2024-02-18 04:22:19 +00:00
|
|
|
const PROXY_SEZNAM = false;
|
|
|
|
const PROXY_NAVER = false;
|
2024-02-26 16:31:52 +00:00
|
|
|
const PROXY_MWMBL = false;
|
2023-11-07 13:04:56 +00:00
|
|
|
const PROXY_FTM = false; // findthatmeme
|
|
|
|
const PROXY_IMGUR = false;
|
|
|
|
const PROXY_YANDEX_W = false; // yandex web
|
|
|
|
const PROXY_YANDEX_I = false; // yandex images
|
|
|
|
const PROXY_YANDEX_V = false; // yandex videos
|
|
|
|
|
|
|
|
//
|
|
|
|
// Scraper-specific parameters
|
|
|
|
//
|
|
|
|
|
|
|
|
// SOUNDCLOUD
|
|
|
|
// Get these parameters by making a search on soundcloud with network
|
|
|
|
// tab open, then filter URLs using "search?q=". (No need to login)
|
2024-03-20 15:19:27 +00:00
|
|
|
const SC_USER_ID = "447501-577662-794348-352629";
|
|
|
|
const SC_CLIENT_TOKEN = "VNc62l3wxDWS0Ol62j5UYNc1gsZ3UXPv";
|
2023-11-07 13:04:56 +00:00
|
|
|
|
|
|
|
// MARGINALIA
|
|
|
|
// Get an API key by contacting the Marginalia.nu maintainer. The "public" key
|
|
|
|
// works but is almost always rate-limited.
|
|
|
|
const MARGINALIA_API_KEY = "public";
|
|
|
|
}
|