Open Closed

how to add login via web3 wallets as external login method? #5869


User avatar
0
hitaspdotnet created

I want to support login via wallet, where the users have a linked web3 wallet to their account. Is there any useful document/article around this? We have the wallet address and a base64 public key after login submitted from the client.


5 Answer(s)
  • User Avatar
    -1
    Anjali_Musmade created
    Support Team Support Team Member

    Hello hitaspdotnet,

    Please check this if find helpful for you https://plugins.miniorange.com/asp-net-web3-login-setup-guide

    Regards, Anjali

  • User Avatar
    0
    hitaspdotnet created

    I want to add it as a module top of abp identity, why you answer me with setup guide of a plugin that not related to abp

  • User Avatar
    0
    Anjali_Musmade created
    Support Team Support Team Member

    Hello hitaspdotnet,

    Apologies for inconvenience I will check and get back to you asap

    Regards

  • User Avatar
    0
    Anjali_Musmade created
    Support Team Support Team Member

    Hi

    if you can integrate web3 login in asp.net core you can do the same process in abp.io

    in abp io once you get necessary details(claims) from the web3 as an external authentication you can modify SignInManager to register or login with the user https://docs.abp.io/en/abp/2.9/How-To/Customize-SignIn-Manager

    https://github.com/dotnet/aspnetcore/blob/c56aa320c32ee5429d60647782c91d53ac765865/src/Identity/Core/src/SignInManager.cs#L638-L674

    https://learn.microsoft.com/en-us/aspnet/web-api/overview/security/external-authentication-services

    How to create module : https://docs.abp.io/en/commercial/latest/abp-suite/create-module-solution#adding-your-new-abp-module-to-your-main-solution

    Also please checkout this link if it is useful : https://github.com/abpframework/abp/issues/5343

  • User Avatar
    0
    hitaspdotnet created

    Thank you for reply, For who has same question, Useful link is this article. we need to extend the user entity with wallet address and public key. we need to create custom user manager to getting user ID by their wallet address and redirect them to the Web3LoginController.Login after validating the public key or Web3LoginController.Register for new users.

Made with ❤️ on ABP v9.1.0-preview. Updated on December 13, 2024, 06:09