@michael@thms.uk
@michael@thms.uk avatar

michael

@michael@thms.uk

Full stack web developer currently working mostly with #PHP / #Laravel, Vanilla #Javascript and #SCSS. Love learning more about (almost) anything, but particularly #MySQL and #InfoSec. Currently learning Arabic. Husband, father of two boys, Christian.

This profile is from a federated server and may be incomplete. Browse more on the original instance.

michael, to random
@michael@thms.uk avatar

Woha, this is unexpected: in a future update mastodon will automatically turn off open registration if no mod has logged in for a week or longer:

https://github.com/mastodon/mastodon/pull/29318

This is great news, and should hopefully significantly cut down on abandoned servers being used to send spam!

(And this is in addition to also having open registrations off by default on new servers.)

Great news!

#mastoadmin #spam

michael, (edited ) to random
@michael@thms.uk avatar

PSA: It looks like mastodon.social has implemented hCAPTCHA on their signups yesterday.

So, if you have limited / suspended mastodon.social because of the spam issue, you may wish to reconsider this.

This will also likely mean that spammers will move to different instances (already seeing them targeting mastodon.world).

You may wish to consider implementing hCAPTCHA yourself to protect your own instance, and here is the relevant PR:

https://github.com/mastodon/mastodon/pull/25019

The reason I'm suggesting this, is because if you are a small/medium instance with open registrations, and spammers find and abuse your instance, I imagine that other instances will limit/suspend your instance without hesitation, given how willing some were to limit/suspend the much larger mastodon.social.

But do note this comment on the PR:

“To give some context to people seeing this: this is an emergency feature backport from Glitch SOC to help mitigating an ongoing spam wave, this feature may not make it in a next release, or with significative changes.”

Edited to add: multiple people have rightly commented on the accessibility concerns with hCaptcha: hCaptcha is really really really bad for blind and visually impaired people.

Please have a look at this excellent reply for more details:

https://dragonscave.space/@Mayana/110383119877022255

michael, to AWS
@michael@thms.uk avatar

What on earth?! Amazon S3 charges you for unauthorised requests to S3?!

That's just absolutely insane! I better check my AWS account and delete any unused buckets I have in there …

https://medium.com/@maciej.pocwierz/how-an-empty-s3-bucket-can-make-your-aws-bill-explode-934a383cb8b1

#aws #s3 #infosec #webdev #cloud

michael, (edited ) to mastodon
@michael@thms.uk avatar

It looks like relay.fedi.buzz is going to break once #mastodon 4.2 comes out:

https://github.com/mastodon/mastodon/pull/23989

This is VERY bad news for users of small instances like myself.

I do understand the reasoning behind it, and I'm not sure there is a good alternative. But it sure feels a bit like a deja vu from the self hosted email days ...

#mastoAdmin #singleuserinstance #relays #FediBuzz

arstechnica, to random
@arstechnica@mastodon.social avatar

GitHub besieged by millions of malicious repositories in ongoing attack

GitHub keeps removing malware-laced repositories, but thousands remain.

https://arstechnica.com/security/2024/02/github-besieged-by-millions-of-malicious-repositories-in-ongoing-attack/?utm_brand=arstechnica&utm_social-type=owned&utm_source=mastodon&utm_medium=social

michael,
@michael@thms.uk avatar

@arstechnica yikes, that’s not good. Wonder what happens when/if Copilot gets trained on those malicious forks 😬

michael, to php
@michael@thms.uk avatar

Today I was reminded that Enums where only introduced into PHP with version 8.1, which is less than 2 years old.

It’s one of my favourite little additions to PHP ever, and I really don’t want to work in a codebase that doesn’t have Enum support ever again. (I actually upgraded two apps I’m responsible for to 8.1 shortly after release, just to gain Enum support).

michael, to fediverse
@michael@thms.uk avatar

#FediFetcher is now on v4.2.1:

New in this release, you can now fetch replies to any posts you've favourited, as suggested by @eddie

For full details, see the release page:

https://github.com/nanos/FediFetcher/releases/tag/v4.2.1

#mastodon #mastoadmin #fediadmin #SingleUserInstance

michael, to php
@michael@thms.uk avatar

Really happy to see that Jetbrain's PHP Annotated this month includes 2 mastodon embeds and no twitter ones!

Going in the right direction there, imo.

https://blog.jetbrains.com/phpstorm/2024/01/php-annotated-january-2024/

#php #jetbrains #phpannotated

michael, to random
@michael@thms.uk avatar

I've noticed a lot of chatter about setting up Elasticsearch for Mastodon 4.2's new full text search over the last few days, including what hardware is required, how difficult is it, etc.

So I thought I’d write down my experience, including the hardware I'm running Elasticsearch on for my single user instance:

https://blog.thms.uk/2023/09/mastodon-elasticsearch?utm_source=mastodon

#mastoAdmin #singleUserInstance #FullTextSearch #Elasticsearch

michael, (edited ) to random
@michael@thms.uk avatar

https://peakd.com/philosophy/@crell/2ciyfu-you-are-wrong

Excellent post by @Crell

I think he expresses a lot of things that I have held for a long time. And I believe more and more (although I might be wrong of course 😉) that people not grasping these things is a big big reason for the polarisation and partisanship of our age.

So, read the article! And pay particular attention to the four takeaways at the bottom.

michael, to CSS
@michael@thms.uk avatar

https://ishadeed.com/article/virtual-keyboard-api/

Pretty neat article! I didn’t know about the virtual keyboard API before, but it does appear to solve a lot of very common problems

michael, to php
@michael@thms.uk avatar

LOL. released a version of their with a very interesting bug, and didn't fix it until about 3 weeks later 😬

Tell me you don't have without telling me you don't have tests 🤣

https://github.com/BingAds/BingAds-PHP-SDK/pull/185/commits/0a185b559010384b709987c2bd18db0095728e98

michael, to fediverse
@michael@thms.uk avatar

I've just released v5.0.0 of FediFetcher

This release brings no new features, but simplifies and unifies configuration of it: Instead of a large list of command line flags / environment variables, FediFetcher is now configured using a JSON file.

You don't need to update to this version immediately, but if you are running FediFetcher as a GitHub Action, you'll need to update and create a JSON file with options eventually, as configuration through Environment variables will no longer be possible going forward.

THIS IS A BREAKING CHANGE, so please read the release notes for detailed instructions, and let me know if you have any questions.

https://github.com/nanos/FediFetcher/releases/tag/v5.0.0

#mastoAdmin #SingleUserInstance #Mastodon #missingReplies #FediFetcher

michael, to random
@michael@thms.uk avatar

To those battling the spam:

I wrote a script a while ago that automatically suspends users who post images with a certain hashtag.

My understanding is that a big part of the currrent spam wave is posting images with the hashtag 'l診断メーカー

In that case you might find this script useful:

https://blog.thms.uk/2023/02/mastodon-block-tags

michael, to CSS
@michael@thms.uk avatar

This is an excellent article by @Kilian

I’m not a big fan of summary/details generally because it’s just too inconsistent, but dialogs are great. And I didn’t actually know about input type="color" yet.

Well worth a read.

https://www.htmhell.dev/adventcalendar/2023/2/

#css #js #JavaScript #html #Frontend #Webdev #Webdevelopment

michael, (edited ) to mastodon
@michael@thms.uk avatar

I just checked, and it appears that only about 1% of all 300k Mastodon users that my instance knows about currently have opted into full text search 😢

Really hoping that number will increase!

Also, does anyone know how Mastodon indexes users from non-Mastodon fediverse servers? These presumably don't have the indexable flag set. I hope Mastodon still indexes those, given that pretty much all other Fediverse software indexes all users?!

(edit: been asked a few times how i got those numbers: Two simple SQL queries: select count(*) from accounts; followed by select count(*) from accounts where indexable = true;)

#mastoadmin #mastodon #FullTextSearch

michael, to random
@michael@thms.uk avatar

has reached 100 stars and 90 forks 🥳

Amazing to see something I built just for myself being useful for so many!

michael, to random
@michael@thms.uk avatar

I know it's been a long time since I tagged a new version of FediFetcher, but it's time to do so again:

I just released version 7.0.3. This is mostly a maintenance release fixing a number of bugs, but we also introduce support for the Iceshrimp fork of Misskey.

Please check the release notes for full details including update instructions:

https://github.com/nanos/FediFetcher/releases/tag/v7.0.3

I think this is actually the first release where I haven't contributed any code myself. A huge thank you to the amazing contributors @toadking, @root, @zotan, @jonas, @jaytay, and IhoBas (sorry, I don't know your fedi handle)

#MastoAdmin #MastoAdmins #FediAdmin #SingleUserInstance #FediFetcher

michael, to Laravel
@michael@thms.uk avatar

Been playing around with Laravel Livewire a bit today, and it’s quite cool actually.

Really a powerful way to quickly get an app with interactivity going, if you can’t or don’t want to use a JS framework.

shawnhooper, (edited ) to random
@shawnhooper@fosstodon.org avatar

Oooh, I can quote post now?! Nice.

Is that a client thing (Ivory) or a Mastodon instance thing ?

michael,
@michael@thms.uk avatar

@shawnhooper probably also worth pointing out that the display of the quoted post therefore also depends on the client:

Most now support ‘quote boosting’ (ie a special preview for links to mastodon posts), but some (notably the official mastodon web and mobile clients) do not.

One could say quote boosts degrade gracefully 😁

michael, to php
@michael@thms.uk avatar
michael, to php
@michael@thms.uk avatar

Got to say: Just been through upgrading an app from 8.1 to 8.3 and it's really nice and painfree.

Very few breaking changes, and the few that are there are stuff that a sensible person would've addressed a long time ago.

Unfortuantely that means that apart from readonly classes, there are also few exciting new things in there. But I guess these also are just point updates after all…

Almost boring 😉 (Not a bad thing! Stability is also nice.)

BeAware, to mastodon

Is there any reason to keep a service like mailgun if I don't have emails turned on for my instance and I won't be receiving new sign ups?

michael,
@michael@thms.uk avatar

@BeAware I think Mailgun by default sort of suggests setting up mx records, but you don’t need them if you only use Mailgun for mastodon, and can remove them without any effect whatsoever.

Personally I use Mailgun for sending from mastodon, and Fastmail for everything else on the same domain. It’s definitely possible

BeAware, to fediverse

So....I want to migrate from Mastodon to Sharkey. The catch is, I would LIKE to end up back on my current domain....is this possible at all?

I have a domain I could park a Sharkey instance to migrate to, but if I make a new Sharkey instance on my current domain after I shut the Mastodon instance down, will I be able to migrate back with little issue?🤔

#Fediverse #Mastodon #MastoAdmin #FediAdmin #Sharkey #SharkeyAdmin

michael,
@michael@thms.uk avatar

@BeAware you might be able to do this via a 2 step migration:

Firstly migrate to an instance at temp.beware.live. Then do a self destruct on your old instance. Importantly wait for all sidekiq jobs (including retries of failed jobs!) to finish afterwards. This may take hours, days, or weeks.

Finally set up a new instance on your domain and migrate to it.

This may or may not work, so do at your own risk, but this is the only way I could conceptually imagine it might work. I’ve never heard of anyone actually attempting it, though, so this seems unknown territory…

michael, to php
@michael@thms.uk avatar

I’ve been fully convinced of Value Objects for quite some time now. It’s extremely rare I use primitive values these days.

If you still need convincing, you should read this great article:

“Embracing the Value Object pattern in PHP 8.2 significantly enhances code quality, making it more robust and maintainable.”

Indeed it does!

https://dev.to/cnastasi/value-objects-in-php-8-building-a-better-code-38k8

#PHP

michael,
@michael@thms.uk avatar

Really good follow up to this article:

Advanced Value Objects in PHP 8

https://dev.to/cnastasi/advanced-value-objects-in-php-8-1lp0

#PHP

  • All
  • Subscribed
  • Moderated
  • Favorites
  • provamag3
  • thenastyranch
  • magazineikmin
  • ethstaker
  • GTA5RPClips
  • InstantRegret
  • rosin
  • love
  • Youngstown
  • slotface
  • khanakhh
  • kavyap
  • everett
  • DreamBathrooms
  • megavids
  • osvaldo12
  • tester
  • cisconetworking
  • tacticalgear
  • ngwrru68w68
  • Durango
  • cubers
  • mdbf
  • normalnudes
  • anitta
  • modclub
  • Leos
  • JUstTest
  • All magazines