AsmBB

Power
Login Register

Integration with a different login system
0

#15767 (ツ) earthendev
Created 24.02.2019, read: 4982 times

While researching forum software for a browser game website, I stumbled upon this cool software, which fits my requirements almost perfectly (at least as advertized). Plus I know how to code x86/x86_64 asm and have done a couple of things with it myself.

There's one thing I require though: I need to use a single login system (with Google and Facebook sign-on support for higher conversion rates) for both the forum and the website. I have not decided on a web framework for the website yet (maybe I'll just code it in ASM ;)), but in any case I either need to have an API to query ASMBB user status (to log them into the website automatically with their forum credentials) or to add ASMBB users programatically (to log them into the forum automatically with their website credentials).

I don't mind coding something myself, but maybe there's a system in place that I could use? I haven't looked at much of the ASMBB code yet. Can this be done with a plugin?

By the way, how scalable is the sqlite database? Have you run into any capacity problems so far? I'm going to use my own postgres db for my data but would there be a way to swap out the forum DB if needed?

#15768 (ツ) johnfound
Created 25.02.2019, read: 4969 times
earthendev

While researching forum software for a browser game website, I stumbled upon this cool software, which fits my requirements almost perfectly (at least as advertized). Plus I know how to code x86/x86_64 asm and have done a couple of things with it myself.

There's one thing I require though: I need to use a single login system (with Google and Facebook sign-on support for higher conversion rates) for both the forum and the website. I have not decided on a web framework for the website yet (maybe I'll just code it in ASM ;)), but in any case I either need to have an API to query ASMBB user status (to log them into the website automatically with their forum credentials) or to add ASMBB users programatically (to log them into the forum automatically with their website credentials).

I don't mind coding something myself, but maybe there's a system in place that I could use? I haven't looked at much of the ASMBB code yet. Can this be done with a plugin?

By the way, how scalable is the sqlite database? Have you run into any capacity problems so far? I'm going to use my own postgres db for my data but would there be a way to swap out the forum DB if needed?

Well, nothing of this is available out-of-the-box. A real plugin interface, based on dynamic libraries is planned, but not implemented yet.

But implementing at least part of these requirements seems to be not so hard. The internal structure of AsmBB allows easy addition of new functions and in fact all functions of AsmBB are some kind of plugins, but in source code form. Every function resides in its own source file and has standard interface to the engine.

Authentication through some authentication protocol such as OpenID, OAuth or similar (facebook, google, whatever) is not implemented mainly because of my total ignorance about these protocols and how they can be used at all. In addition, I have some doubts about the privacy protection when using such protocols - probably again because of my ignorance on the subject.

The SQLite database is not scalable at all. I mean you can'r spread it in several servers or similar. But you can setup AsmBB and sqlite on one dedicated server and the web server and other parts of the system on another server(s).

This demo installation of AsmBB is working on a VPS with 1GB of RAM, 1 CPU core (at 2.4GHz) and can serve several thousands of visitors simultaneously. The tests have been made during several slashdot effect events, but never with real users activity. The load, according to my tests is divided approximately 50%-50% between the template rendering engine and the sqlite database.

#15769 (ツ) earthendev
Last edited: 25.02.2019 by earthendev, read: 4958 times
johnfound

The SQLite database is not scalable at all. I mean you can'r spread it in several servers or similar. But you can setup AsmBB and sqlite on one dedicated server and the web server and other parts of the system on another server(s).

This demo installation of AsmBB is working on a VPS with 1GB of RAM, 1 CPU core (at 2.4GHz) and can serve several thousands of visitors simultaneously. The tests have been made during several slashdot effect events, but never with real users activity. The load, according to my tests is divided approximately 50%-50% between the template rendering engine and the sqlite database.

Yeah that should work. I predict a visitor count at around that scale (mostly readers though, not so many active posters). A dedicated server should be able to handle that.

Doing things using generic OAuth2 is awfully complicated as I understand it, but you can just use the JavaScript provided by Facebook or Google to handle authentication on the client and then send the User ID to their server for verification (see e.g. https://developers.google.com/identity/sign-in/web/backend-auth) and again verify the reply. This last part is the hard part, because you need to implement signature verification.

When everything has been verified, you create a user account in your own app using the info you got from Google. I am most likely going to do that outside ASMBB (using one of the client libraries) and implement a simple API that ASMBB can call into, e.g. using a socket. Can I just use POSIX sockets for this?

On a totally unrelated note: I'd appreciate if you could add an overview of the current thread on the !post page, so you can quickly refer back to other posts. Or an inline reply feature maybe... (edit: I just noticed the edit window already works like that :)

Integration with a different login system
0

AsmBB v3.0 (check-in: a316dab8b98d07d9); SQLite v3.42.0 (check-in: 831d0fb2836b71c9);
©2016..2023 John Found; Licensed under EUPL. Powered by Assembly language Created with Fresh IDE