diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..159c9cc --- /dev/null +++ b/LICENSE @@ -0,0 +1,37 @@ +Copyright 2021-2022 MiranDaniel + + +The Software is provided to you by the Licensor under +the License, as defined below, subject to the following +condition. + +Without limiting other conditions in the +License, the grant of rights under the License will not +include, and the License does not grant to you, the +right to Sell the Software. + +For purposes of the +foregoing, “Sell” means practicing any or all of the +rights granted to you under the License to provide to +third parties, for a fee or other consideration +(including without limitation fees for hosting or +consulting/ support services related to the Software), a +product or service whose value derives, entirely or +substantially, from the functionality of the Software. +Any license notice or attribution required by the +License must also include this Commons Cause License +Condition notice. + + +THE SOFTWARE IS PROVIDED "AS IS", +WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT +OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH +THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + + diff --git a/README.md b/README.md index ad6e1f9..7bf31de 100644 --- a/README.md +++ b/README.md @@ -7,4 +7,48 @@ This branch hosts the f1rewall 2.0 version. Still under development, do not use, feel free to contribute :) +--- + +Version: `2.0.0-alpha.1` + +--- + +## License + +```text +Copyright 2021-2022 MiranDaniel + + +The Software is provided to you by the Licensor under +the License, as defined below, subject to the following +condition. + +Without limiting other conditions in the +License, the grant of rights under the License will not +include, and the License does not grant to you, the +right to Sell the Software. + +For purposes of the +foregoing, “Sell” means practicing any or all of the +rights granted to you under the License to provide to +third parties, for a fee or other consideration +(including without limitation fees for hosting or +consulting/ support services related to the Software), a +product or service whose value derives, entirely or +substantially, from the functionality of the Software. +Any license notice or attribution required by the +License must also include this Commons Cause License +Condition notice. + +THE SOFTWARE IS PROVIDED "AS IS", +WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT +OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH +THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +``` diff --git a/blueprints/dash.py b/blueprints/dash.py new file mode 100644 index 0000000..3b9728d --- /dev/null +++ b/blueprints/dash.py @@ -0,0 +1,28 @@ +import multiprocessing + +from flask import Blueprint, render_template, abort, request, redirect +from source import conf +from source import utils +from source import captcha +from source import invites + +import threading + +utils.check_os() +utils.check_setup() + +dashboard = Blueprint('dashboard', __name__, + template_folder='templates') + +configuration = conf.load_conf() + + +@dashboard.route('/admin/login') +def login(): + return render_template( + "login.jinja2", + captcha=configuration.captcha, + public=configuration.captcha_public, + args=configuration.args, + kwargs=configuration.kwargs + ) diff --git a/main.py b/main.py index fb42cfa..a01c637 100644 --- a/main.py +++ b/main.py @@ -1,6 +1,13 @@ + +# +# Version 2.0.0-alpha.1 +# + + from flask import Flask from blueprints import gate +from blueprints import dash from source import utils @@ -17,6 +24,7 @@ app = Flask(__name__) app.register_blueprint(gate.gateway) +app.register_blueprint(dash.dashboard) @catch_goodbye() diff --git a/source/invites.py b/source/invites.py index 1b91d66..fc76134 100644 --- a/source/invites.py +++ b/source/invites.py @@ -21,7 +21,7 @@ def __init__(self): self.poolSizeDefault = self.poolSize def debug(self): - return # disable debug mode + #return # disable debug mode print("::InvitePool::DEBUG:: " + str(self.pool)) diff --git a/static/background.png b/static/background.png new file mode 100644 index 0000000..1271528 Binary files /dev/null and b/static/background.png differ diff --git a/static/wordmark.png b/static/wordmark.png new file mode 100644 index 0000000..7ce74a3 Binary files /dev/null and b/static/wordmark.png differ diff --git a/templates/admin.jinja2 b/templates/admin.jinja2 new file mode 100644 index 0000000..566549b --- /dev/null +++ b/templates/admin.jinja2 @@ -0,0 +1,10 @@ + + +
+ +