diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..b30e85b --- /dev/null +++ b/.dockerignore @@ -0,0 +1,6 @@ +.git/ +.idea/ +.dockerignore +.gitignore +notes.txt +readme.md diff --git a/.gitignore b/.gitignore index 6ef86a9..ddf9741 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,7 @@ +# IDE-related folders .idea/ -.htaccess -files/ -content/page/ + +# Static resources resources/Azias/imgs/*.exe resources/Azias/imgs/*.url resources/ChartJs/ @@ -10,3 +10,7 @@ resources/GoogleFonts/ resources/HalfMoon/ resources/Icons8/ resources/Quantum/ + +# Other folders +content/page/ +files/ diff --git a/.htaccess b/.htaccess new file mode 100644 index 0000000..905bd5e --- /dev/null +++ b/.htaccess @@ -0,0 +1,78 @@ +# Prevent access to .htaccess + + Order allow,deny + Deny from all + + +# Redirecting HTTP traffic to HTTPS. (Keep commented on localhost !) +# This is handled other services, but it should still be enabled in production just to be safe. +#RewriteEngine On +#RewriteCond %{SERVER_PORT} 80 +#RewriteRule ^(.*)$ https://nibblepoker.lu/$1 [R,L] + +# Correcting some default options for security and language/content redirection. +# FollowSymlinks is on since it required for "mod_rewrite" and the server is jailed. +Options -Indexes +FollowSymlinks -ExecCGI + +# Custom error pages. +ErrorDocument 403 /403.php +ErrorDocument 404 /404.php + +# Setting some headers for security. +# TODO: Implement a proper module check and redirection to clean 503 error page if module is not enabled ! +Header always set X-Detected-Country "NK" +Header always set X-Frame-Options "deny" +Header always set Content-Security-Policy "default-src 'self'; object-src 'none'; child-src 'self'; frame-ancestors 'none'; upgrade-insecure-requests; block-all-mixed-content" +Header always set X-XSS-Protection " 1; mode=block" +Header always set Referrer-Policy "no-referrer" +Header always set X-Content-Type-Options "nosniff" +Header always set Strict-Transport-Security "max-age=31536000; includeSubDomains; preload" +Header always set Cache-Control "max-age=300, public" +# FIXME: Apparently, the 'Permissions-Policy' header is not properly formatted, IDK why... +Header always set Permissions-Policy "accelerometer=(),autoplay=(),camera=(),display-capture=(),document-domain=(),encrypted-media=(),fullscreen=(),geolocation=(),gyroscope=(),magnetometer=(),microphone=(),midi=(),payment=(),picture-in-picture=(),publickey-credentials-get=(),screen-wake-lock=(),sync-xhr=(self),usb=(),web-share=(),xr-spatial-tracking=()" +Header always set Access-Control-Allow-Origin "*" +Header unset X-Powered-By +Header always set X-Powered-By "Amiga 1200, Kickstart 3.1" + +# Handling all other redirections. + + # TODO: Raise error if not available + RewriteEngine On + + # Sending a 404 for git and IDEs folders just in case they ever get copied to the web server, + # or if one of the honeypot files is acessed directly. + # A 404 is preferred to prevent further scanning of this folder and from raising some flags. + RedirectMatch 404 ^.*\.?(git|vs(code)|idea).* + RedirectMatch 404 ^.*honeypot.* + + # Languages. (Does not work with a regex) + RewriteRule ^en/(.*)$ /$1 [QSA] + RewriteRule ^fr/(.*)$ /$1 [QSA] + RewriteRule ^lb/(.*)$ /$1 [QSA] + + # Content categories. - Should be removed ? + #RewriteRule ^((en|fr|lb)/)?blog/article/(.*)$ /content/page/$1 [QSA] + #RewriteRule ^((en|fr|lb)/)?programming/(applications|tutorials|tools)/(.*)$ /content/page/$1 [QSA] + ##RewriteRule ^((en|fr|lb)/)?electronics/ham/(.*)$ /content/page/$1 [QSA] + + # Content root pages. - Should be removed ? + #RewriteRule ^((en|fr|lb)/)?programming/(purebasic|python|others)/(.*)$ /content/$1 [QSA] + #RewriteRule ^((en|fr|lb)/)?electronics/(iot|experiments)/(.*)$ /content/$1 [QSA] + + # Content pages. (Old regex are taken care of by the "content/index.php" page) + RewriteRule ^((en|fr|lb)/)?(blog|programming|electronics)/(.*)$ /content/$1 [QSA] + + # Internal redirections for scanning and exploit attempts. + # These rules are here since they're easier to implement in the .htaccess. + #RewriteRule ^.*(install|xmlrpc)\.php.*$ /honeypot/file-php.php [QSA] + RewriteRule ^.*\.xml.*$ /honeypot/file-xml.php [QSA] + RewriteRule ^.*wlwmanifest\.xml.*$ /honeypot/file-xml-wlwmanifest.php [QSA] + RewriteRule ^.*\.env.*$ /honeypot/file-env.php [QSA] + #RewriteRule ^.*(ap(i|p.*)|cms|sit[eo]|shop.*|wp.*).*$ /honeypot/folder.php [QSA] + + # Cases left to handle: + # * /wp-admin/post.php?id=whatever + # * /public /vendor /storage + + # TODO: Implement bee-movie themed tarpit once I have a rate-limiting solution in place ! + diff --git a/403.php b/403.php index 79eaf1e..dd21867 100644 --- a/403.php +++ b/403.php @@ -24,6 +24,32 @@ +
+
+
+
+
+
+
+
+
+
+

+
+
+
+
+
+
+

+

+
+
+
+
+
+
+ diff --git a/404.php b/404.php index 15aca4c..525c0e9 100644 --- a/404.php +++ b/404.php @@ -24,6 +24,32 @@ +
+
+
+
+
+
+
+
+
+
+

+
+
+
+
+
+
+

+

+
+
+
+
+
+
+ diff --git a/commons/strings.json b/commons/strings.json index aa57f9c..0d384c0 100644 --- a/commons/strings.json +++ b/commons/strings.json @@ -48,7 +48,7 @@ "privacy.complaint.text.1": "Should you wish to report a complaint or if you feel that our privacy policy has not addressed your concern in a satisfactory manner, you may contact your national Data Protection Authority (DPA).", "privacy.complaint.text.2": "More information on this procedure can be found on the following websites:", "error.common.details.title": "Error details", - "error.4xx.title": "HTTP client error", + "error.4xx.title": "HTTP Client Error", "error.4xx.text": "${error.4xx.text}", "error.4xx.button.back": "Go back", "error.403.title": "403 Error", diff --git a/contact/index.php b/contact/index.php index 138be6d..7614904 100644 --- a/contact/index.php +++ b/contact/index.php @@ -39,7 +39,7 @@
-
+
diff --git a/honeypot/file-env.php b/honeypot/file-env.php new file mode 100644 index 0000000..c0db10a --- /dev/null +++ b/honeypot/file-env.php @@ -0,0 +1,27 @@ + \ No newline at end of file diff --git a/honeypot/file-php.php b/honeypot/file-php.php new file mode 100644 index 0000000..c9d0547 --- /dev/null +++ b/honeypot/file-php.php @@ -0,0 +1,14 @@ + + + + + + + Document + + +

Title

+

PHP file jail

+ + diff --git a/honeypot/file-xml-wlwmanifest.php b/honeypot/file-xml-wlwmanifest.php new file mode 100644 index 0000000..cf1b749 --- /dev/null +++ b/honeypot/file-xml-wlwmanifest.php @@ -0,0 +1,46 @@ + + + + + + WordPress + Yes + Yes + + + + WordPress + images/wlw/wp-icon.png + images/wlw/wp-watermark.png + View site + Dashboard + + + + + + + + + + + + + +"); +?> \ No newline at end of file diff --git a/honeypot/file-xml.php b/honeypot/file-xml.php new file mode 100644 index 0000000..27205c1 --- /dev/null +++ b/honeypot/file-xml.php @@ -0,0 +1,28 @@ + + + VtigerVulnPlugin + + Tools + 1.01 + + 7.0.0 + 7.* + + + LICENSE.txt + + + + + + enabled + + + + disabled + + +"); +?> \ No newline at end of file diff --git a/honeypot/folder.php b/honeypot/folder.php new file mode 100644 index 0000000..1f84570 --- /dev/null +++ b/honeypot/folder.php @@ -0,0 +1,14 @@ + + + + + + + Document + + +

Title

+

Folder jail

+ + diff --git a/index.php b/index.php index 068246e..fe0147e 100644 --- a/index.php +++ b/index.php @@ -15,7 +15,7 @@
- +
-
+
-
- +

PB-ListComPort @@ -88,7 +87,9 @@ Cli tool that lists COM ports in different parsable formats.
  Link

- +
+
+

Youtube-Auto-Archiver @@ -101,7 +102,9 @@ Automatic archival solutions for YouTube livestreams and uploads.
  Link

- +
+
+

Excel-Worksheet-Password-Remover @@ -141,7 +144,7 @@

-
+

1st February 2022
Going the self-hosted route. diff --git a/readme.md b/readme.md index d0a10d3..6b6bb7e 100644 --- a/readme.md +++ b/readme.md @@ -1,2 +1,28 @@ # Website - NibblePoker.lu TODO. + +## Warning +TODO: Remark about folders and files to remove ! + +## Requirements +These files are not present in this repo since they +would clutter the commits and potentially break some licensing rules. + +### Required +These files are required for the website to work properly !
+ +* Font Awesome Pro v5.15.3 + * `/resources/FontAwesomePro/` +* HalfMoon v1.1.1 + * `/resources/HalfMoon/` +* Quantum + * `/resources/Quantum/` + +### Optional +These files are leftovers from previous projects and might be required somewhere. +* ChartJS + * `/resources/ChartJs/` +* Material Icons + * `/resources/GoogleFonts/MaterialIcons/` +* Icons8 - Color & Fluent private packs + * `/resources/Icons8/` diff --git a/resources/Azias/css/nibblepoker.lu.css b/resources/Azias/css/nibblepoker.lu.css index e2b2a44..34f7435 100644 --- a/resources/Azias/css/nibblepoker.lu.css +++ b/resources/Azias/css/nibblepoker.lu.css @@ -91,6 +91,28 @@ div#body-overlay { image-rendering: pixelated; } +hr, hr.dark-mode { + background-color: rgba(0, 0, 0, 0) !important; + background: rgb(93,95,97); + background: radial-gradient(circle, rgba(83,85,87,0.8) 0%, rgba(65,67,69,0.65) 75%, rgba(17,20,23,0) 100%); + opacity: 0.75; +} + +@media (min-width: 993px) { + .l-lab-web { + background: linear-gradient(90deg, rgba(101,144,134,0.3) 0%, rgba(101,144,134,0.2) 1.5px, rgba(101,144,134,0.0) 7px); + clip-path: polygon(4px 0%, 100% 0, 100% 100%, 4px 100%, 0 calc(100% - 4px), 0 4px); + } + .l-lab-office { + background: linear-gradient(90deg, rgba(64,84,59,0.5) 0%, rgba(64,84,59,0.3) 2px, rgba(64,84,59,0.0) 7px); + clip-path: polygon(4px 0%, 100% 0, 100% 100%, 4px 100%, 0 calc(100% - 4px), 0 4px); + } + .l-lab-app { + background: linear-gradient(90deg, rgba(156,23,34,0.4) 0%, rgba(156,23,34,0.3) 1.5px, rgba(156,23,34,0.0) 7px); + clip-path: polygon(4px 0%, 100% 0, 100% 100%, 4px 100%, 0 calc(100% - 4px), 0 4px); + } +} + /* Trash */ /*.lang-icon { height: var(--base-line-height); diff --git a/robots.txt b/robots.txt new file mode 100644 index 0000000..accc53f --- /dev/null +++ b/robots.txt @@ -0,0 +1,4 @@ +User-agent: * +Allow: / + +Sitemap: https://nibblepoker.lu/sitemap.xml