Valerie Pond [Sat, 4 Feb 2023 16:44:12 +0000 (16:44 +0000)]
Redirect back on login
This makes it so that when your session times out and you are redirected to the login page, you will be redirected back to the page you were on before you were logged out.
Valerie Pond [Sat, 4 Feb 2023 12:03:21 +0000 (12:03 +0000)]
Merge pull request #8 from Madriix/patch-1
Update unrealircd-admin.css to fix incorrect width on a div which was causing the width of the page to be large enough to cause a horizontal scrollbar.
Madriix [Sat, 4 Feb 2023 11:59:32 +0000 (12:59 +0100)]
Update unrealircd-admin.css
Tested on Firefox: as soon as we are on any page, there is the scrollbar activated at the bottom of page.
The div that could pose a problem is the div that contains the nav tag with the "container-fluid" class, the default bootstrap contains a width: 100% and this width when it is removed the scrollbar is removed.
This css disables/resets the width. It seems to work pretty well on my Firefox browser.
Valerie Pond [Mon, 23 Jan 2023 23:54:48 +0000 (23:54 +0000)]
Rather large update, please see commit notes
With this update:
- WebPanel version shows in the footer for logged-in users (sql_auth)
- Made things look much better on mobiles; before, the navigation bar covered most of the mobile screen and was generally not visually appealing. So now when the screen is a mobile, the navigation bar will collapse into a collapsible menu.
- Separated `Name Bans` and `Server Ban Exceptions` into their own sub-menu pages. TODO: There is some weird overlap with the list background highlight.
-Started on user_meta: as in, when they last logged in, what IP they are using or used, recent actions taken, and most importantly, permissions.
- Added a few hooks which allow plugins to do more:
- `HOOKTYPE_PRE_HEADER`
- `HOOKTYPE_HEADER`
- `HOOKTYPE_PRE_FOOTER`
- `HOOKTYPE_FOOTER`
These hooks are relatively self-explanatory. There is however another hook of a different nature.
- `HOOKTYPE_NOTIFICATION`
You will need to run this from your plugin as well as catch functions from it. This won't be run many places in the source so it's up to you to send notifications. Maybe some other plugin wants to show notifications somewhere else or do something different, while still being able to load your plugin and receive notifications for it, and vice versa.
Valerie Pond [Sat, 21 Jan 2023 23:54:12 +0000 (23:54 +0000)]
IP WHOIS: Add a built-in IP WHOIS page
This adds `ip-whois.php` and friends which provides a built-in page for doing a `WHOIS` on an IP address. No more having to go to some IP WHOIS website to view information about potentially spooky characters on your network ;)
Valerie Pond [Thu, 19 Jan 2023 23:43:20 +0000 (23:43 +0000)]
Add blacklist options
This adds a new configuration item: `DNSBL`.
This is checked against non-logged in users on every page. If they are not logged in they get blacklist checked and then redirected to the login page, providing their IP was not blacklisted.
If it was blacklisted the user will be redirected to an error screen with a cute dog on it.
I have also spent a considerable amount of time trying (and failing) to make it look good on mobile devices, so this is a small commit ;)
Valerie Pond [Wed, 18 Jan 2023 22:55:13 +0000 (22:55 +0000)]
Add ability to add and delete access to the panel
Beware, at this very commit, any user you add can delete any other user including you.
In case of this, you can always add yourself back through the config or delete their stuff in the SQL database.
Valerie Pond [Wed, 18 Jan 2023 22:53:23 +0000 (22:53 +0000)]
Convert array/splat parameter in class-message
Even though a splat operator converts the input to an array, if you pass an array instead of parameters, the first item in the splat array will be the array you need. This lets pass an array as well as a splat operator and it'll "just work"
PeGaSuS [Wed, 18 Jan 2023 14:30:30 +0000 (15:30 +0100)]
Update header.php
On my setup, I have `BASE_URL` set to `/`, using Apache as webserver.
If I click on the top left, where says `UnrealIRCd Admin Panel`, I'm sent to https://index.php/ which, obviously, doesn't exist.
Removing `/index.php` seems to solve the issue on my end. I don't know about other webservers/BASE_URL locations, but should work for all.
Valerie Pond [Mon, 16 Jan 2023 00:41:33 +0000 (00:41 +0000)]
Make some better links to filters for user
this puts links and lookups in places:
- You can now click the 'Opers' button on the overview to view the users page filtered by opers only
- Servers listed in user index and details now link to server details
Valerie Pond [Sun, 15 Jan 2023 23:49:30 +0000 (23:49 +0000)]
update overview and add record users
this converts things from a bunch of queries to the easier to use "stats.get" (thanks @syzop).
this also adds in a 'Record' label in the users card, showing the record user amount.