diff --git a/backend/app.py b/backend/app.py index 753f350..e673214 100644 --- a/backend/app.py +++ b/backend/app.py @@ -1,10 +1,7 @@ from base64 import b64decode -from datetime import datetime, timedelta import sqlite3, uvicorn, sys, secrets, re, os, asyncio, httpx, urllib, websockets -from tabnanny import check -from typing import Union -from fastapi import FastAPI, Request, HTTPException, WebSocket, Depends -from pydantic import BaseModel +from fastapi import FastAPI, HTTPException, WebSocket, Depends +from pydantic import BaseModel, BaseSettings from fastapi.responses import FileResponse, StreamingResponse from utils import SQLite, KeyValueStorage, gen_internal_port, ProxyManager, from_name_get_id, STATUS from fastapi.security import OAuth2PasswordBearer, OAuth2PasswordRequestForm @@ -20,16 +17,22 @@ db = SQLite('db/firegex.db') conf = KeyValueStorage(db) firewall = ProxyManager(db) -JWT_ALGORITHM="HS256" -JWT_SECRET = secrets.token_hex(32) -APP_STATUS = "init" -REACT_BUILD_DIR = "../frontend/build/" if not ON_DOCKER else "frontend/" -REACT_HTML_PATH = os.path.join(REACT_BUILD_DIR,"index.html") + +class Settings(BaseSettings): + JWT_ALGORITHM: str = "HS256" + REACT_BUILD_DIR: str = "../frontend/build/" if not ON_DOCKER else "frontend/" + REACT_HTML_PATH: str = os.path.join(REACT_BUILD_DIR,"index.html") + + +settings = Settings() oauth2_scheme = OAuth2PasswordBearer(tokenUrl="/api/login", auto_error=False) crypto = CryptContext(schemes=["bcrypt"], deprecated="auto") app = FastAPI(debug=DEBUG) +def APP_STATUS(): return "init" if conf.get("password") is None else "run" +def JWT_SECRET(): return conf.get("secret") + @app.on_event("shutdown") async def shutdown_event(): await firewall.close() @@ -37,50 +40,21 @@ async def shutdown_event(): @app.on_event("startup") async def startup_event(): - global APP_STATUS - db.connect() - db.create_schema({ - 'services': { - 'status': 'VARCHAR(100) NOT NULL', - 'service_id': 'VARCHAR(100) PRIMARY KEY', - 'internal_port': 'INT NOT NULL CHECK(internal_port > 0 and internal_port < 65536) UNIQUE', - 'public_port': 'INT NOT NULL CHECK(internal_port > 0 and internal_port < 65536) UNIQUE', - 'name': 'VARCHAR(100) NOT NULL' - }, - 'regexes': { - 'regex': 'TEXT NOT NULL', - 'mode': 'VARCHAR(1) NOT NULL', - 'service_id': 'VARCHAR(100) NOT NULL', - 'is_blacklist': 'BOOLEAN NOT NULL CHECK (is_blacklist IN (0, 1))', - 'blocked_packets': 'INTEGER UNSIGNED NOT NULL DEFAULT 0', - 'regex_id': 'INTEGER PRIMARY KEY', - 'is_case_sensitive' : 'BOOLEAN NOT NULL CHECK (is_case_sensitive IN (0, 1))', - 'FOREIGN KEY (service_id)':'REFERENCES services (service_id)', - }, - 'keys_values': { - 'key': 'VARCHAR(100) PRIMARY KEY', - 'value': 'VARCHAR(100) NOT NULL', - }, - }) - db.query("CREATE UNIQUE INDEX IF NOT EXISTS unique_regex_service ON regexes (regex,service_id,is_blacklist,mode,is_case_sensitive);") - - if not conf.get("password") is None: - APP_STATUS = "run" - + db.init() + if not JWT_SECRET(): conf.put("secret", secrets.token_hex(32)) await firewall.reload() + def create_access_token(data: dict): - global JWT_SECRET to_encode = data.copy() - encoded_jwt = jwt.encode(to_encode, JWT_SECRET, algorithm=JWT_ALGORITHM) + encoded_jwt = jwt.encode(to_encode, JWT_SECRET(), algorithm=settings.JWT_ALGORITHM) return encoded_jwt async def check_login(token: str = Depends(oauth2_scheme)): - global JWT_SECRET if not token: return False try: - payload = jwt.decode(token, JWT_SECRET, algorithms=[JWT_ALGORITHM]) + payload = jwt.decode(token, JWT_SECRET(), algorithms=[settings.JWT_ALGORITHM]) logged_in: bool = payload.get("logged_in") except JWTError: return False @@ -97,9 +71,8 @@ async def is_loggined(auth: bool = Depends(check_login)): @app.get("/api/status") async def get_status(auth: bool = Depends(check_login)): - global APP_STATUS return { - "status":APP_STATUS, + "status": APP_STATUS(), "loggined": auth } @@ -112,29 +85,23 @@ class PasswordChangeForm(BaseModel): @app.post("/api/login") async def login_api(form: OAuth2PasswordRequestForm = Depends()): - global APP_STATUS, JWT_SECRET - - if APP_STATUS != "run": raise HTTPException(status_code=400) - + if APP_STATUS() != "run": raise HTTPException(status_code=400) if form.password == "": return {"status":"Cannot insert an empty password!"} await asyncio.sleep(0.3) # No bruteforce :) if crypto.verify(form.password, conf.get("password")): - print("access granted, good job") return {"access_token": create_access_token({"logged_in": True}), "token_type": "bearer"} raise HTTPException(406,"Wrong password!") @app.post('/api/change-password') async def change_password(form: PasswordChangeForm, auth: bool = Depends(is_loggined)): - - global APP_STATUS, JWT_SECRET - if APP_STATUS != "run": raise HTTPException(status_code=400) + if APP_STATUS() != "run": raise HTTPException(status_code=400) if form.password == "": return {"status":"Cannot insert an empty password!"} if form.expire: - JWT_SECRET = secrets.token_hex(32) + conf.put("secret", secrets.token_hex(32)) hash_psw = crypto.hash(form.password) conf.put("password",hash_psw) @@ -143,14 +110,11 @@ async def change_password(form: PasswordChangeForm, auth: bool = Depends(is_logg @app.post('/api/set-password') async def set_password(form: PasswordForm): - global APP_STATUS, JWT_SECRET - if APP_STATUS != "init": raise HTTPException(status_code=400) + if APP_STATUS() != "init": raise HTTPException(status_code=400) if form.password == "": return {"status":"Cannot insert an empty password!"} - hash_psw = crypto.hash(form.password) conf.put("password",hash_psw) - APP_STATUS = "run" return {"status":"ok", "access_token": create_access_token({"logged_in": True})} @app.get('/api/general-stats') @@ -165,7 +129,6 @@ async def get_general_stats(auth: bool = Depends(is_loggined)): @app.get('/api/services') async def get_services(auth: bool = Depends(is_loggined)): - return db.query(""" SELECT s.service_id `id`, @@ -199,25 +162,21 @@ async def get_service(service_id: str, auth: bool = Depends(is_loggined)): @app.get('/api/service/{service_id}/stop') async def get_service_stop(service_id: str, auth: bool = Depends(is_loggined)): - await firewall.get(service_id).next(STATUS.STOP) return {'status': 'ok'} @app.get('/api/service/{service_id}/pause') async def get_service_pause(service_id: str, auth: bool = Depends(is_loggined)): - await firewall.get(service_id).next(STATUS.PAUSE) return {'status': 'ok'} @app.get('/api/service/{service_id}/start') async def get_service_start(service_id: str, auth: bool = Depends(is_loggined)): - await firewall.get(service_id).next(STATUS.ACTIVE) return {'status': 'ok'} @app.get('/api/service/{service_id}/delete') async def get_service_delete(service_id: str, auth: bool = Depends(is_loggined)): - db.query('DELETE FROM services WHERE service_id = ?;', service_id) db.query('DELETE FROM regexes WHERE service_id = ?;', service_id) await firewall.remove(service_id) @@ -226,7 +185,6 @@ async def get_service_delete(service_id: str, auth: bool = Depends(is_loggined)) @app.get('/api/service/{service_id}/regen-port') async def get_regen_port(service_id: str, auth: bool = Depends(is_loggined)): - db.query('UPDATE services SET internal_port = ? WHERE service_id = ?;', gen_internal_port(db), service_id) await firewall.get(service_id).update_port() return {'status': 'ok'} @@ -234,7 +192,6 @@ async def get_regen_port(service_id: str, auth: bool = Depends(is_loggined)): @app.get('/api/service/{service_id}/regexes') async def get_service_regexes(service_id: str, auth: bool = Depends(is_loggined)): - return db.query(""" SELECT regex, mode, regex_id `id`, service_id, is_blacklist, @@ -244,7 +201,6 @@ async def get_service_regexes(service_id: str, auth: bool = Depends(is_loggined) @app.get('/api/regex/{regex_id}') async def get_regex_id(regex_id: int, auth: bool = Depends(is_loggined)): - res = db.query(""" SELECT regex, mode, regex_id `id`, service_id, is_blacklist, @@ -256,9 +212,7 @@ async def get_regex_id(regex_id: int, auth: bool = Depends(is_loggined)): @app.get('/api/regex/{regex_id}/delete') async def get_regex_delete(regex_id: int, auth: bool = Depends(is_loggined)): - res = db.query('SELECT * FROM regexes WHERE regex_id = ?;', regex_id) - if len(res) != 0: db.query('DELETE FROM regexes WHERE regex_id = ?;', regex_id) await firewall.get(res[0]["service_id"]).update_filters() @@ -274,7 +228,6 @@ class RegexAddForm(BaseModel): @app.post('/api/regexes/add') async def post_regexes_add(form: RegexAddForm, auth: bool = Depends(is_loggined)): - try: re.compile(b64decode(form.regex)) except Exception: @@ -294,7 +247,6 @@ class ServiceAddForm(BaseModel): @app.post('/api/services/add') async def post_services_add(form: ServiceAddForm, auth: bool = Depends(is_loggined)): - serv_id = from_name_get_id(form.name) try: db.query("INSERT INTO services (name, service_id, internal_port, public_port, status) VALUES (?, ?, ?, ?, ?)", @@ -312,9 +264,9 @@ async def frontend_debug_proxy(path): return StreamingResponse(resp.aiter_bytes(),status_code=resp.status_code) async def react_deploy(path): - file_request = os.path.join(REACT_BUILD_DIR, path) + file_request = os.path.join(settings.REACT_BUILD_DIR, path) if not os.path.isfile(file_request): - return FileResponse(REACT_HTML_PATH, media_type='text/html') + return FileResponse(settings.REACT_HTML_PATH, media_type='text/html') else: return FileResponse(file_request) @@ -356,5 +308,5 @@ if __name__ == '__main__': port=int(os.getenv("PORT","4444")), reload=DEBUG, access_log=DEBUG, - workers=2 + workers=1 ) diff --git a/backend/proxy/__init__.py b/backend/proxy/__init__.py index bf782d2..3df3060 100755 --- a/backend/proxy/__init__.py +++ b/backend/proxy/__init__.py @@ -69,7 +69,6 @@ class Proxy: async with self.status_change: if self.isactive(): self.process.kill() - self.process = None return False return True @@ -92,9 +91,7 @@ class Proxy: await self.update_config(filters_codes) def isactive(self): - if self.process and not self.process.returncode is None: - self.process = None - return True if self.process else False + return self.process and self.process.returncode is None async def pause(self): if self.isactive(): diff --git a/backend/proxy/proxy.cpp b/backend/proxy/proxy.cpp index 9987bb3..15b52ac 100644 --- a/backend/proxy/proxy.cpp +++ b/backend/proxy/proxy.cpp @@ -443,7 +443,6 @@ private: }; - int main(int argc, char* argv[]) { if (argc < 5) @@ -500,4 +499,4 @@ int main(int argc, char* argv[]) #endif return 0; -} \ No newline at end of file +} diff --git a/backend/utils.py b/backend/utils.py index 1cd6f0b..aeb57d3 100755 --- a/backend/utils.py +++ b/backend/utils.py @@ -46,6 +46,33 @@ class SQLite(): cur.close() try: self.conn.commit() except Exception: pass + + def init(self): + self.connect() + self.create_schema({ + 'services': { + 'status': 'VARCHAR(100) NOT NULL', + 'service_id': 'VARCHAR(100) PRIMARY KEY', + 'internal_port': 'INT NOT NULL CHECK(internal_port > 0 and internal_port < 65536) UNIQUE', + 'public_port': 'INT NOT NULL CHECK(internal_port > 0 and internal_port < 65536) UNIQUE', + 'name': 'VARCHAR(100) NOT NULL' + }, + 'regexes': { + 'regex': 'TEXT NOT NULL', + 'mode': 'VARCHAR(1) NOT NULL', + 'service_id': 'VARCHAR(100) NOT NULL', + 'is_blacklist': 'BOOLEAN NOT NULL CHECK (is_blacklist IN (0, 1))', + 'blocked_packets': 'INTEGER UNSIGNED NOT NULL DEFAULT 0', + 'regex_id': 'INTEGER PRIMARY KEY', + 'is_case_sensitive' : 'BOOLEAN NOT NULL CHECK (is_case_sensitive IN (0, 1))', + 'FOREIGN KEY (service_id)':'REFERENCES services (service_id)', + }, + 'keys_values': { + 'key': 'VARCHAR(100) PRIMARY KEY', + 'value': 'VARCHAR(100) NOT NULL', + }, + }) + self.query("CREATE UNIQUE INDEX IF NOT EXISTS unique_regex_service ON regexes (regex,service_id,is_blacklist,mode,is_case_sensitive);") class KeyValueStorage: def __init__(self, db): @@ -70,8 +97,7 @@ class STATUS: PAUSE = "pause" ACTIVE = "active" -class ServiceNotFoundException(Exception): - pass +class ServiceNotFoundException(Exception): pass class ServiceManager: def __init__(self, id, db): @@ -83,7 +109,8 @@ class ServiceManager: ) self.status = STATUS.STOP self.filters = {} - self._proxy_update() + self._update_port_from_db() + self._update_filters_from_db() self.lock = asyncio.Lock() self.starter = None @@ -97,11 +124,7 @@ class ServiceManager: if len(res) == 0: raise ServiceNotFoundException() self.proxy.internal_port = res[0]["internal_port"] self.proxy.public_port = res[0]["public_port"] - - def _proxy_update(self): - self._update_port_from_db() - self._update_filters_from_db() - + def _update_filters_from_db(self): res = self.db.query(""" SELECT @@ -133,8 +156,8 @@ class ServiceManager: ) self.proxy.filters = list(self.filters.values()) - def __update_status_db(self, id, status): - self.db.query("UPDATE services SET status = ? WHERE service_id = ?;", status, id) + def __update_status_db(self, status): + self.db.query("UPDATE services SET status = ? WHERE service_id = ?;", status, self.id) async def next(self,to): async with self.lock: @@ -171,7 +194,7 @@ class ServiceManager: def _set_status(self,status): self.status = status - self.__update_status_db(self.id,status) + self.__update_status_db(status) async def update_filters(self): @@ -222,7 +245,10 @@ class ProxyManager: await self.proxy_table[srv_id].next(req_status) def get(self,id): - return self.proxy_table[id] + if id in self.proxy_table: + return self.proxy_table[id] + else: + raise ServiceNotFoundException() def check_port_is_open(port): try: diff --git a/frontend/build/asset-manifest.json b/frontend/build/asset-manifest.json old mode 100644 new mode 100755 index bcf2b47..7672e7d --- a/frontend/build/asset-manifest.json +++ b/frontend/build/asset-manifest.json @@ -1,13 +1,13 @@ { "files": { - "main.css": "/static/css/main.0efd334b.css", - "main.js": "/static/js/main.dbb30aee.js", + "main.css": "/static/css/main.c375ae17.css", + "main.js": "/static/js/main.e6c85636.js", "index.html": "/index.html", - "main.0efd334b.css.map": "/static/css/main.0efd334b.css.map", - "main.dbb30aee.js.map": "/static/js/main.dbb30aee.js.map" + "main.c375ae17.css.map": "/static/css/main.c375ae17.css.map", + "main.e6c85636.js.map": "/static/js/main.e6c85636.js.map" }, "entrypoints": [ - "static/css/main.0efd334b.css", - "static/js/main.dbb30aee.js" + "static/css/main.c375ae17.css", + "static/js/main.e6c85636.js" ] } \ No newline at end of file diff --git a/frontend/build/index.html b/frontend/build/index.html old mode 100644 new mode 100755 index aed712f..103ab3b --- a/frontend/build/index.html +++ b/frontend/build/index.html @@ -1 +1 @@ -Firegex
\ No newline at end of file +Firegex
\ No newline at end of file diff --git a/frontend/build/static/css/main.0efd334b.css b/frontend/build/static/css/main.0efd334b.css deleted file mode 100644 index efc67a4..0000000 --- a/frontend/build/static/css/main.0efd334b.css +++ /dev/null @@ -1,2 +0,0 @@ -@import url(https://fonts.googleapis.com/css2?family=Lato&display=swap);.center-flex,.center-flex-row{align-items:center;display:flex;justify-content:center}.center-flex-row{flex-direction:column}.flex-spacer{flex-grow:1}.Footer_center-flex-row__EeEEN,.Footer_center-flex__vCncJ,.Footer_footer__PxxIj{align-items:center;display:flex;justify-content:center}.Footer_center-flex-row__EeEEN{flex-direction:column}.Footer_flex-spacer__MHTsy{flex-grow:1}.Footer_footer__PxxIj{background-color:#242a33;height:150px;margin-top:50px}.Header_header__OKWO7{align-items:center;background-color:#242a33;display:flex;height:140px;justify-content:center;width:100%}.Header_logo__shVBB{height:70%;margin-left:40px;width:200px}body{font-family:Lato,sans-serif;margin:0}.ServiceRow_center-flex-row__g7ljt,.ServiceRow_center-flex__BYani,.ServiceRow_row__X48wF{align-items:center;display:flex;justify-content:center}.ServiceRow_center-flex-row__g7ljt{flex-direction:column}.ServiceRow_flex-spacer__zolmX{flex-grow:1}::-webkit-scrollbar{background:#333;cursor:pointer;margin:3px;width:12px}::-webkit-scrollbar-thumb{background:#757575;border-radius:8px}.ServiceRow_row__X48wF{border-radius:20px;margin:10px;padding:30px 0;width:95%}.ServiceRow_name__fL\+Lz{color:#fff;font-size:2.3em;font-weight:bolder;margin-bottom:13px;margin-right:10px}.RegexView_box__PVbdO{margin:5px;padding:30px}.RegexView_regex_text__rxij9{background-color:#25262b;border-radius:15px;padding:10px} -/*# sourceMappingURL=main.0efd334b.css.map*/ \ No newline at end of file diff --git a/frontend/build/static/css/main.c375ae17.css b/frontend/build/static/css/main.c375ae17.css new file mode 100755 index 0000000..b5a5378 --- /dev/null +++ b/frontend/build/static/css/main.c375ae17.css @@ -0,0 +1,2 @@ +@import url(https://fonts.googleapis.com/css2?family=Lato&display=swap);.center-flex,.center-flex-row{align-items:center;display:flex;justify-content:center}.center-flex-row{flex-direction:column}.flex-spacer{flex-grow:1}.Footer_center-flex-row__yo4XA,.Footer_center-flex__uvxL9,.Footer_footer__S9pCA{align-items:center;display:flex;justify-content:center}.Footer_center-flex-row__yo4XA{flex-direction:column}.Footer_flex-spacer__VEUAB{flex-grow:1}.Footer_footer__S9pCA{background-color:#242a33;height:150px;margin-top:50px}.Header_header__Ri4em{align-items:center;background-color:#242a33;display:flex;height:140px;justify-content:center;width:100%}.Header_logo__3Bvhn{height:70%;margin-left:40px;width:200px}body{font-family:Lato,sans-serif;margin:0}.ServiceRow_center-flex-row__E5vBK,.ServiceRow_center-flex__hmJif,.ServiceRow_row__-A-i2{align-items:center;display:flex;justify-content:center}.ServiceRow_center-flex-row__E5vBK{flex-direction:column}.ServiceRow_flex-spacer__vmC0u{flex-grow:1}::-webkit-scrollbar{background:#333;cursor:pointer;margin:3px;width:12px}::-webkit-scrollbar-thumb{background:#757575;border-radius:8px}.ServiceRow_row__-A-i2{border-radius:20px;margin:10px;padding:30px 0;width:95%}.ServiceRow_name__6f1O6{color:#fff;font-size:2.3em;font-weight:bolder;margin-bottom:13px;margin-right:10px}.RegexView_box__g-S5R{margin:5px;padding:30px}.RegexView_regex_text__Fy5MY{background-color:#25262b;border-radius:15px;padding:10px} +/*# sourceMappingURL=main.c375ae17.css.map*/ \ No newline at end of file diff --git a/frontend/build/static/css/main.0efd334b.css.map b/frontend/build/static/css/main.c375ae17.css.map old mode 100644 new mode 100755 similarity index 94% rename from frontend/build/static/css/main.0efd334b.css.map rename to frontend/build/static/css/main.c375ae17.css.map index a650831..2def520 --- a/frontend/build/static/css/main.0efd334b.css.map +++ b/frontend/build/static/css/main.c375ae17.css.map @@ -1 +1 @@ -{"version":3,"file":"static/css/main.0efd334b.css","mappings":"wEAUA,8BAGE,mBAFA,aACA,sBACA,CAGF,iBAEE,sBAGF,aACE,YAZF,gFAGE,mBAFA,aACA,sBACA,CAGF,+BAEE,sBAGF,2BACE,YCnBF,sBAGI,yBAFA,aACA,eCJY,CCEhB,sBAKI,mBAFA,wBDLY,CCMZ,aAFA,aAIA,uBALA,UAKA,CAGJ,oBAGI,WADA,iBADA,WAEA,CHVJ,KAEE,4BADA,QACA,CAGF,yFAGE,mBAFA,aACA,sBACA,CAGF,mCAEE,sBAGF,+BACE,YAGF,oBAGE,gBACA,eAFA,UAAU,CADV,UAGA,CAEF,0BACE,mBACA,kBI9BF,uBAGI,mBACA,YAFA,eADA,SAGA,CAIJ,yBAKI,WAJA,gBACA,mBAEA,mBADA,iBAEA,CCbJ,sBAEI,UAAS,CADT,YACU,CAGd,6BAEI,wBHPS,CGQT,mBAFA,YAEA","sources":["index.scss","components/Footer/Footer.module.scss","_vars.scss","components/Header/Header.module.scss","components/ServiceRow/ServiceRow.module.scss","components/RegexView/RegexView.module.scss"],"sourcesContent":["\n@use \"vars\" as *;\n\n@import url('https://fonts.googleapis.com/css2?family=Lato&display=swap');\n\nbody {\n margin: 0;\n font-family: 'Lato', sans-serif;\n}\n\n.center-flex{\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.center-flex-row{\n @extend .center-flex;\n flex-direction: column;\n}\n\n.flex-spacer{\n flex-grow: 1;\n}\n\n::-webkit-scrollbar {\n width: 12px;\n margin:3px;\n background: #333;\n cursor: pointer;\n}\n::-webkit-scrollbar-thumb {\n background: #757575;\n border-radius: 8px;\n}","@use \"../../vars\" as *;\r\n@use \"../../index.scss\" as *;\r\n\r\n.footer{\r\n height: 150px;\r\n margin-top: 50px;\r\n background-color: $primary_color;\r\n @extend .center-flex;\r\n}","\r\n$primary_color: #242a33;\r\n$second_color: #1A1B1E;\r\n$third_color:#25262b;\r\n","\r\n@use \"../../vars\" as *;\r\n\r\n.header{\r\n width: 100%;\r\n height: 140px;\r\n background-color: $primary_color;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n}\r\n\r\n.logo{\r\n width: 200px;\r\n margin-left: 40px;\r\n height: 70%;\r\n}","\r\n@use \"../../index.scss\" as *;\r\n\r\n.row{\r\n width: 95%;\r\n padding: 30px 0px;\r\n border-radius: 20px;\r\n margin: 10px;\r\n @extend .center-flex;\r\n}\r\n\r\n.name{\r\n font-size: 2.3em;\r\n font-weight: bolder;\r\n margin-right: 10px;\r\n margin-bottom: 13px;\r\n color:#FFF;\r\n}","\r\n@use \"../../vars\" as *;\r\n\r\n.box{\r\n padding:30px;\r\n margin:5px;\r\n}\r\n\r\n.regex_text{\r\n padding: 10px;\r\n background-color: $third_color;\r\n border-radius: 15px;\r\n}"],"names":[],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"static/css/main.c375ae17.css","mappings":"wEAUA,8BAGE,mBAFA,aACA,sBACA,CAGF,iBAEE,sBAGF,aACE,YAZF,gFAGE,mBAFA,aACA,sBACA,CAGF,+BAEE,sBAGF,2BACE,YCnBF,sBAGI,yBAFA,aACA,eCJY,CCEhB,sBAKI,mBAFA,wBDLY,CCMZ,aAFA,aAIA,uBALA,UAKA,CAGJ,oBAGI,WADA,iBADA,WAEA,CHVJ,KAEE,4BADA,QACA,CAGF,yFAGE,mBAFA,aACA,sBACA,CAGF,mCAEE,sBAGF,+BACE,YAGF,oBAGE,gBACA,eAFA,UAAU,CADV,UAGA,CAEF,0BACE,mBACA,kBI9BF,uBAGI,mBACA,YAFA,eADA,SAGA,CAIJ,wBAKI,WAJA,gBACA,mBAEA,mBADA,iBAEA,CCbJ,sBAEI,UAAS,CADT,YACU,CAGd,6BAEI,wBHPS,CGQT,mBAFA,YAEA","sources":["index.scss","components/Footer/Footer.module.scss","_vars.scss","components/Header/Header.module.scss","components/ServiceRow/ServiceRow.module.scss","components/RegexView/RegexView.module.scss"],"sourcesContent":["\n@use \"vars\" as *;\n\n@import url('https://fonts.googleapis.com/css2?family=Lato&display=swap');\n\nbody {\n margin: 0;\n font-family: 'Lato', sans-serif;\n}\n\n.center-flex{\n display: flex;\n justify-content: center;\n align-items: center;\n}\n\n.center-flex-row{\n @extend .center-flex;\n flex-direction: column;\n}\n\n.flex-spacer{\n flex-grow: 1;\n}\n\n::-webkit-scrollbar {\n width: 12px;\n margin:3px;\n background: #333;\n cursor: pointer;\n}\n::-webkit-scrollbar-thumb {\n background: #757575;\n border-radius: 8px;\n}","@use \"../../vars\" as *;\r\n@use \"../../index.scss\" as *;\r\n\r\n.footer{\r\n height: 150px;\r\n margin-top: 50px;\r\n background-color: $primary_color;\r\n @extend .center-flex;\r\n}","\r\n$primary_color: #242a33;\r\n$second_color: #1A1B1E;\r\n$third_color:#25262b;\r\n","\r\n@use \"../../vars\" as *;\r\n\r\n.header{\r\n width: 100%;\r\n height: 140px;\r\n background-color: $primary_color;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n}\r\n\r\n.logo{\r\n width: 200px;\r\n margin-left: 40px;\r\n height: 70%;\r\n}","\r\n@use \"../../index.scss\" as *;\r\n\r\n.row{\r\n width: 95%;\r\n padding: 30px 0px;\r\n border-radius: 20px;\r\n margin: 10px;\r\n @extend .center-flex;\r\n}\r\n\r\n.name{\r\n font-size: 2.3em;\r\n font-weight: bolder;\r\n margin-right: 10px;\r\n margin-bottom: 13px;\r\n color:#FFF;\r\n}","\r\n@use \"../../vars\" as *;\r\n\r\n.box{\r\n padding:30px;\r\n margin:5px;\r\n}\r\n\r\n.regex_text{\r\n padding: 10px;\r\n background-color: $third_color;\r\n border-radius: 15px;\r\n}"],"names":[],"sourceRoot":""} \ No newline at end of file diff --git a/frontend/build/static/js/main.dbb30aee.js b/frontend/build/static/js/main.e6c85636.js old mode 100644 new mode 100755 similarity index 91% rename from frontend/build/static/js/main.dbb30aee.js rename to frontend/build/static/js/main.e6c85636.js index 2c277dd..87338ac --- a/frontend/build/static/js/main.dbb30aee.js +++ b/frontend/build/static/js/main.e6c85636.js @@ -1,3 +1,3 @@ -/*! For license information please see main.dbb30aee.js.LICENSE.txt */ -!function(){var e={506:function(e){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},575:function(e){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},913:function(e){function t(e,t){for(var n=0;n0?i-4:i;for(n=0;n>16&255,s[u++]=t>>8&255,s[u++]=255&t;2===l&&(t=r[e.charCodeAt(n)]<<2|r[e.charCodeAt(n+1)]>>4,s[u++]=255&t);1===l&&(t=r[e.charCodeAt(n)]<<10|r[e.charCodeAt(n+1)]<<4|r[e.charCodeAt(n+2)]>>2,s[u++]=t>>8&255,s[u++]=255&t);return s},t.fromByteArray=function(e){for(var t,r=e.length,o=r%3,a=[],i=16383,l=0,c=r-o;lc?c:l+i));1===o?(t=e[r-1],a.push(n[t>>2]+n[t<<4&63]+"==")):2===o&&(t=(e[r-2]<<8)+e[r-1],a.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"="));return a.join("")};for(var n=[],r=[],o="undefined"!==typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i=0,l=a.length;i0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function s(e,t,r){for(var o,a,i=[],l=t;l>18&63]+n[a>>12&63]+n[a>>6&63]+n[63&a]);return i.join("")}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},778:function(e,t,n){"use strict";var r=n(575).default,o=n(913).default,a=n(506).default,i=n(205).default,l=n(842).default,c=n(9),s=n(38),u="function"===typeof Symbol&&"function"===typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.lW=p,t.h2=50;var f=2147483647;function d(e){if(e>f)throw new RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,p.prototype),t}function p(e,t,n){if("number"===typeof e){if("string"===typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return y(e)}return h(e,t,n)}function h(e,t,n){if("string"===typeof e)return function(e,t){"string"===typeof t&&""!==t||(t="utf8");if(!p.isEncoding(t))throw new TypeError("Unknown encoding: "+t);var n=0|w(e,t),r=d(n),o=r.write(e,t);o!==n&&(r=r.slice(0,o));return r}(e,t);if(ArrayBuffer.isView(e))return function(e){if(ee(e,Uint8Array)){var t=new Uint8Array(e);return g(t.buffer,t.byteOffset,t.byteLength)}return v(e)}(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(ee(e,ArrayBuffer)||e&&ee(e.buffer,ArrayBuffer))return g(e,t,n);if("undefined"!==typeof SharedArrayBuffer&&(ee(e,SharedArrayBuffer)||e&&ee(e.buffer,SharedArrayBuffer)))return g(e,t,n);if("number"===typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');var r=e.valueOf&&e.valueOf();if(null!=r&&r!==e)return p.from(r,t,n);var o=function(e){if(p.isBuffer(e)){var t=0|b(e.length),n=d(t);return 0===n.length||e.copy(n,0,0,t),n}if(void 0!==e.length)return"number"!==typeof e.length||te(e.length)?d(0):v(e);if("Buffer"===e.type&&Array.isArray(e.data))return v(e.data)}(e);if(o)return o;if("undefined"!==typeof Symbol&&null!=Symbol.toPrimitive&&"function"===typeof e[Symbol.toPrimitive])return p.from(e[Symbol.toPrimitive]("string"),t,n);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function m(e){if("number"!==typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function y(e){return m(e),d(e<0?0:0|b(e))}function v(e){for(var t=e.length<0?0:0|b(e.length),n=d(t),r=0;r=f)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+f.toString(16)+" bytes");return 0|e}function w(e,t){if(p.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||ee(e,ArrayBuffer))return e.byteLength;if("string"!==typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var n=e.length,r=arguments.length>2&&!0===arguments[2];if(!r&&0===n)return 0;for(var o=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return K(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return Z(e).length;default:if(o)return r?-1:K(e).length;t=(""+t).toLowerCase(),o=!0}}function x(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return R(this,t,n);case"utf8":case"utf-8":return I(this,t,n);case"ascii":return T(this,t,n);case"latin1":case"binary":return L(this,t,n);case"base64":return N(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return M(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function k(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function S(e,t,n,r,o){if(0===e.length)return-1;if("string"===typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),te(n=+n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"===typeof t&&(t=p.from(t,r)),p.isBuffer(t))return 0===t.length?-1:O(e,t,n,r,o);if("number"===typeof t)return t&=255,"function"===typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):O(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function O(e,t,n,r,o){var a,i=1,l=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;i=2,l/=2,c/=2,n/=2}function s(e,t){return 1===i?e[t]:e.readUInt16BE(t*i)}if(o){var u=-1;for(a=n;al&&(n=l-c),a=n;a>=0;a--){for(var f=!0,d=0;do&&(r=o):r=o;var a,i=t.length;for(r>i/2&&(r=i/2),a=0;a>8,o=n%256,a.push(o),a.push(r);return a}(t,e.length-n),e,n,r)}function N(e,t,n){return 0===t&&n===e.length?c.fromByteArray(e):c.fromByteArray(e.slice(t,n))}function I(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o239?4:a>223?3:a>191?2:1;if(o+l<=n){var c=void 0,s=void 0,u=void 0,f=void 0;switch(l){case 1:a<128&&(i=a);break;case 2:128===(192&(c=e[o+1]))&&(f=(31&a)<<6|63&c)>127&&(i=f);break;case 3:c=e[o+1],s=e[o+2],128===(192&c)&&128===(192&s)&&(f=(15&a)<<12|(63&c)<<6|63&s)>2047&&(f<55296||f>57343)&&(i=f);break;case 4:c=e[o+1],s=e[o+2],u=e[o+3],128===(192&c)&&128===(192&s)&&128===(192&u)&&(f=(15&a)<<18|(63&c)<<12|(63&s)<<6|63&u)>65535&&f<1114112&&(i=f)}}null===i?(i=65533,l=1):i>65535&&(i-=65536,r.push(i>>>10&1023|55296),i=56320|1023&i),r.push(i),o+=l}return function(e){var t=e.length;if(t<=_)return String.fromCharCode.apply(String,e);var n="",r=0;for(;rr.length?(p.isBuffer(a)||(a=p.from(a)),a.copy(r,o)):Uint8Array.prototype.set.call(r,a,o);else{if(!p.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(r,o)}o+=a.length}return r},p.byteLength=w,p.prototype._isBuffer=!0,p.prototype.swap16=function(){var e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;tn&&(e+=" ... "),""},u&&(p.prototype[u]=p.prototype.inspect),p.prototype.compare=function(e,t,n,r,o){if(ee(e,Uint8Array)&&(e=p.from(e,e.offset,e.byteLength)),!p.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var a=(o>>>=0)-(r>>>=0),i=(n>>>=0)-(t>>>=0),l=Math.min(a,i),c=this.slice(r,o),s=e.slice(t,n),u=0;u>>=0,isFinite(n)?(n>>>=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var a=!1;;)switch(r){case"hex":return E(this,e,t,n);case"utf8":case"utf-8":return j(this,e,t,n);case"ascii":case"latin1":case"binary":return C(this,e,t,n);case"base64":return z(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,e,t,n);default:if(a)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),a=!0}},p.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var _=4096;function T(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;or)&&(n=r);for(var o="",a=t;an)throw new RangeError("Trying to access beyond buffer length")}function A(e,t,n,r,o,a){if(!p.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||te.length)throw new RangeError("Index out of range")}function F(e,t,n,r,o){Q(t,r,o,e,n,7);var a=Number(t&BigInt(4294967295));e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a;var i=Number(t>>BigInt(32)&BigInt(4294967295));return e[n++]=i,i>>=8,e[n++]=i,i>>=8,e[n++]=i,i>>=8,e[n++]=i,n}function B(e,t,n,r,o){Q(t,r,o,e,n,7);var a=Number(t&BigInt(4294967295));e[n+7]=a,a>>=8,e[n+6]=a,a>>=8,e[n+5]=a,a>>=8,e[n+4]=a;var i=Number(t>>BigInt(32)&BigInt(4294967295));return e[n+3]=i,i>>=8,e[n+2]=i,i>>=8,e[n+1]=i,i>>=8,e[n]=i,n+8}function U(e,t,n,r,o,a){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function W(e,t,n,r,o){return t=+t,n>>>=0,o||U(e,0,n,4),s.write(e,t,n,r,23,4),n+4}function H(e,t,n,r,o){return t=+t,n>>>=0,o||U(e,0,n,8),s.write(e,t,n,r,52,8),n+8}p.prototype.slice=function(e,t){var n=this.length;(e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t>>=0,t>>>=0,n||D(e,t,this.length);for(var r=this[e],o=1,a=0;++a>>=0,t>>>=0,n||D(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},p.prototype.readUint8=p.prototype.readUInt8=function(e,t){return e>>>=0,t||D(e,1,this.length),this[e]},p.prototype.readUint16LE=p.prototype.readUInt16LE=function(e,t){return e>>>=0,t||D(e,2,this.length),this[e]|this[e+1]<<8},p.prototype.readUint16BE=p.prototype.readUInt16BE=function(e,t){return e>>>=0,t||D(e,2,this.length),this[e]<<8|this[e+1]},p.prototype.readUint32LE=p.prototype.readUInt32LE=function(e,t){return e>>>=0,t||D(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},p.prototype.readUint32BE=p.prototype.readUInt32BE=function(e,t){return e>>>=0,t||D(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},p.prototype.readBigUInt64LE=re((function(e){Y(e>>>=0,"offset");var t=this[e],n=this[e+7];void 0!==t&&void 0!==n||G(e,this.length-8);var r=t+this[++e]*Math.pow(2,8)+this[++e]*Math.pow(2,16)+this[++e]*Math.pow(2,24),o=this[++e]+this[++e]*Math.pow(2,8)+this[++e]*Math.pow(2,16)+n*Math.pow(2,24);return BigInt(r)+(BigInt(o)<>>=0,"offset");var t=this[e],n=this[e+7];void 0!==t&&void 0!==n||G(e,this.length-8);var r=t*Math.pow(2,24)+this[++e]*Math.pow(2,16)+this[++e]*Math.pow(2,8)+this[++e],o=this[++e]*Math.pow(2,24)+this[++e]*Math.pow(2,16)+this[++e]*Math.pow(2,8)+n;return(BigInt(r)<>>=0,t>>>=0,n||D(e,t,this.length);for(var r=this[e],o=1,a=0;++a=(o*=128)&&(r-=Math.pow(2,8*t)),r},p.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||D(e,t,this.length);for(var r=t,o=1,a=this[e+--r];r>0&&(o*=256);)a+=this[e+--r]*o;return a>=(o*=128)&&(a-=Math.pow(2,8*t)),a},p.prototype.readInt8=function(e,t){return e>>>=0,t||D(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},p.prototype.readInt16LE=function(e,t){e>>>=0,t||D(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},p.prototype.readInt16BE=function(e,t){e>>>=0,t||D(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},p.prototype.readInt32LE=function(e,t){return e>>>=0,t||D(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},p.prototype.readInt32BE=function(e,t){return e>>>=0,t||D(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},p.prototype.readBigInt64LE=re((function(e){Y(e>>>=0,"offset");var t=this[e],n=this[e+7];void 0!==t&&void 0!==n||G(e,this.length-8);var r=this[e+4]+this[e+5]*Math.pow(2,8)+this[e+6]*Math.pow(2,16)+(n<<24);return(BigInt(r)<>>=0,"offset");var t=this[e],n=this[e+7];void 0!==t&&void 0!==n||G(e,this.length-8);var r=(t<<24)+this[++e]*Math.pow(2,16)+this[++e]*Math.pow(2,8)+this[++e];return(BigInt(r)<>>=0,t||D(e,4,this.length),s.read(this,e,!0,23,4)},p.prototype.readFloatBE=function(e,t){return e>>>=0,t||D(e,4,this.length),s.read(this,e,!1,23,4)},p.prototype.readDoubleLE=function(e,t){return e>>>=0,t||D(e,8,this.length),s.read(this,e,!0,52,8)},p.prototype.readDoubleBE=function(e,t){return e>>>=0,t||D(e,8,this.length),s.read(this,e,!1,52,8)},p.prototype.writeUintLE=p.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t>>>=0,n>>>=0,r)||A(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,a=0;for(this[t]=255&e;++a>>=0,n>>>=0,r)||A(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,a=1;for(this[t+o]=255&e;--o>=0&&(a*=256);)this[t+o]=e/a&255;return t+n},p.prototype.writeUint8=p.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,1,255,0),this[t]=255&e,t+1},p.prototype.writeUint16LE=p.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},p.prototype.writeUint16BE=p.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},p.prototype.writeUint32LE=p.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},p.prototype.writeUint32BE=p.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},p.prototype.writeBigUInt64LE=re((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return F(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),p.prototype.writeBigUInt64BE=re((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return B(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))})),p.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var o=Math.pow(2,8*n-1);A(this,e,t,n,o-1,-o)}var a=0,i=1,l=0;for(this[t]=255&e;++a>0)-l&255;return t+n},p.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var o=Math.pow(2,8*n-1);A(this,e,t,n,o-1,-o)}var a=n-1,i=1,l=0;for(this[t+a]=255&e;--a>=0&&(i*=256);)e<0&&0===l&&0!==this[t+a+1]&&(l=1),this[t+a]=(e/i>>0)-l&255;return t+n},p.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},p.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},p.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},p.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},p.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||A(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},p.prototype.writeBigInt64LE=re((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return F(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),p.prototype.writeBigInt64BE=re((function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return B(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))})),p.prototype.writeFloatLE=function(e,t,n){return W(this,e,t,!0,n)},p.prototype.writeFloatBE=function(e,t,n){return W(this,e,t,!1,n)},p.prototype.writeDoubleLE=function(e,t,n){return H(this,e,t,!0,n)},p.prototype.writeDoubleBE=function(e,t,n){return H(this,e,t,!1,n)},p.prototype.copy=function(e,t,n,r){if(!p.isBuffer(e))throw new TypeError("argument should be a Buffer");if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"===typeof e)for(a=t;a=r+4;n-=3)t="_".concat(e.slice(n-3,n)).concat(t);return"".concat(e.slice(0,n)).concat(t)}function Q(e,t,n,r,o,a){if(e>n||e3?0===t||t===BigInt(0)?">= 0".concat(l," and < 2").concat(l," ** ").concat(8*(a+1)).concat(l):">= -(2".concat(l," ** ").concat(8*(a+1)-1).concat(l,") and < 2 ** ")+"".concat(8*(a+1)-1).concat(l):">= ".concat(t).concat(l," and <= ").concat(n).concat(l),new $.ERR_OUT_OF_RANGE("value",i,e)}!function(e,t,n){Y(t,"offset"),void 0!==e[t]&&void 0!==e[t+n]||G(t,e.length-(n+1))}(r,o,a)}function Y(e,t){if("number"!==typeof e)throw new $.ERR_INVALID_ARG_TYPE(t,"number",e)}function G(e,t,n){if(Math.floor(e)!==e)throw Y(e,n),new $.ERR_OUT_OF_RANGE(n||"offset","an integer",e);if(t<0)throw new $.ERR_BUFFER_OUT_OF_BOUNDS;throw new $.ERR_OUT_OF_RANGE(n||"offset",">= ".concat(n?1:0," and <= ").concat(t),e)}V("ERR_BUFFER_OUT_OF_BOUNDS",(function(e){return e?"".concat(e," is outside of buffer bounds"):"Attempt to access memory outside buffer bounds"}),RangeError),V("ERR_INVALID_ARG_TYPE",(function(e,t){return'The "'.concat(e,'" argument must be of type number. Received type ').concat(typeof t)}),TypeError),V("ERR_OUT_OF_RANGE",(function(e,t,n){var r='The value of "'.concat(e,'" is out of range.'),o=n;return Number.isInteger(n)&&Math.abs(n)>Math.pow(2,32)?o=q(String(n)):"bigint"===typeof n&&(o=String(n),(n>Math.pow(BigInt(2),BigInt(32))||n<-Math.pow(BigInt(2),BigInt(32)))&&(o=q(o)),o+="n"),r+=" It must be ".concat(t,". Received ").concat(o)}),RangeError);var X=/[^+/0-9A-Za-z-_]/g;function K(e,t){var n;t=t||1/0;for(var r=e.length,o=null,a=[],i=0;i55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&a.push(239,191,189);continue}if(i+1===r){(t-=3)>-1&&a.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&a.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&a.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;a.push(n)}else if(n<2048){if((t-=2)<0)break;a.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;a.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;a.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return a}function Z(e){return c.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(X,"")).length<2)return"";for(;e.length%4!==0;)e+="=";return e}(e))}function J(e,t,n,r){var o;for(o=0;o=t.length||o>=e.length);++o)t[o+n]=e[o];return o}function ee(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function te(e){return e!==e}var ne=function(){for(var e="0123456789abcdef",t=new Array(256),n=0;n<16;++n)for(var r=16*n,o=0;o<16;++o)t[r+o]=e[n]+e[o];return t}();function re(e){return"undefined"===typeof BigInt?oe:e}function oe(){throw new Error("BigInt not supported")}},110:function(e,t,n){"use strict";var r=n(441),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},a={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},l={};function c(e){return r.isMemo(e)?i:l[e.$$typeof]||o}l[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},l[r.Memo]=i;var s=Object.defineProperty,u=Object.getOwnPropertyNames,f=Object.getOwnPropertySymbols,d=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!==typeof n){if(h){var o=p(n);o&&o!==h&&e(t,o,r)}var i=u(n);f&&(i=i.concat(f(n)));for(var l=c(t),m=c(n),y=0;y>1,u=-7,f=n?o-1:0,d=n?-1:1,p=e[t+f];for(f+=d,a=p&(1<<-u)-1,p>>=-u,u+=l;u>0;a=256*a+e[t+f],f+=d,u-=8);for(i=a&(1<<-u)-1,a>>=-u,u+=r;u>0;i=256*i+e[t+f],f+=d,u-=8);if(0===a)a=1-s;else{if(a===c)return i?NaN:1/0*(p?-1:1);i+=Math.pow(2,r),a-=s}return(p?-1:1)*i*Math.pow(2,a-r)},t.write=function(e,t,n,r,o,a){var i,l,c,s=8*a-o-1,u=(1<>1,d=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:a-1,h=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(l=isNaN(t)?1:0,i=u):(i=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-i))<1&&(i--,c*=2),(t+=i+f>=1?d/c:d*Math.pow(2,1-f))*c>=2&&(i++,c/=2),i+f>=u?(l=0,i=u):i+f>=1?(l=(t*c-1)*Math.pow(2,o),i+=f):(l=t*Math.pow(2,f-1)*Math.pow(2,o),i=0));o>=8;e[n+p]=255&l,p+=h,l/=256,o-=8);for(i=i<0;e[n+p]=255&i,p+=h,i/=256,s-=8);e[n+p-h]|=128*m}},463:function(e,t,n){"use strict";var r=n(791),o=n(296);function a(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n