Please help me develop a two factor provider

Hello,

please help me develop a default two factor provider app structure. I went through a basic concepts and first app tutorial, but I still can’t undestand the structure. Looking at source codes of other two factor auth apps doesn’t help.

I try to implement twofactor authentication with programmable smart cards into Nextcloud. I have everything ready even with basic PHP code to communicate with the card on user side. I just need to place this code somewhere in freshly created app with some basic settings available.

This project might be expanded in the future using different technology for connecting the smart card by using some JS libraries like web-eid.

Here are a few points which might more elaborate my problem:

  1. What is the minimal code base for such an app?
  2. Is there a need to learn and implement JavaScript and Vue.js code?
  3. Or can I just create basic IProvider and simple security settings for let’s say creating password in PHP and add some UIs and fancy things later?
  4. How are different web technologies (PHP, Js, Vue.js, webpack, some app-specific custom libraries and templates app) connected together?
  5. Which one of them are a necessity to develop a two factor provider
  6. Js files are usually minified in the installed app which makes it unreadable - if I look on their github page, there’s only a readable src folder with readable js files - do those get converted to js folder when installed?

Thanks, Muzosh

Devs used to be on IRC. Unsure, but here is a thread discussing possible use of libera.chat

  1. Some app metatdata via info.xml, a 2FA provider implementation. Possibly some DB back-end to keep track of the smart card registrations
  2. Likely because your app needs a front-end, doesn’t it?
  3. Unlikely but try your luck
  4. Please elaborate what you mean with connected together? PHP runs on the server. JS in the browser.
  5. We’re going in circles but PHP definitley, JS/Vue most likely
  6. The code is compiled in a build step. That happens during development but also before the release package is built.

Have you seen https://docs.nextcloud.com/server/stable/developer_manual/?

I did see the developer manual, but this is my first experience with web development so I hoped somebody might help, sorry.

No worries. Happy hacking!