The post above this one (and bits and pieces of the OP) makes me chuckle a bit, because I didn't really understand how much work I was signing myself up for!
Anyway, it's been quite an adventure but I now have a completely working 2FA patch for this version of SMF.
I would say it took about a week to get a basic implementation mostly finished. After that initial week of work I decided to put it on the back burner and think about things like how it would interact with password resets, etc. I touched it every now and then, making small improvements. The largest amount of work was generating QR codes in PHP (the patch uses no outside code, so this meant a from-scratch implementation).
Then I figured, having only managed to get theymos to accept one tiny patch before, that I should try and see if I can get a bigger patch merged before bugging him with a large one. I tried my luck, here and here (and technically here, too, but that's not really much of a patch, more like a suggestion). It was a little disheartening having so little success with those attempts, and that kind of killed my enthusiasm for finishing the 2FA patch.
I found the energy recently to finish it up, and I'm happy with the final result. I didn't keep a timesheet, but I estimate it took around 80 hours of programming/reading/thinking (excluding the other patches).
After so much work, I'm not really in the mood for another failed attempt to get a patch merged, so to keep my spirits up I think I'll put it out of my mind until the new year. I'll post about it (and send the code to theymos) in
Okay, thanks for reading. I'm not too hopeful, but at least there's a chance that the forum will get 2FA in early 2023!
Edit: Fuggin' finally. Here it is: A concise 2FA/TOTP implementation (SMF patch).