Code Monkey home page Code Monkey logo

authserver's People

Contributors

jafossum avatar torleifs avatar zeldaiv avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

jafossum

authserver's Issues

Make it possible to add Scopes for APIs

Need UI to add Scopes and list existing scopes. A scope is defined with he following model:
ID: (generated by the BackEnd)
Name: The name of the scope
DisplayName: Additional human readable information, often used on ConsentScreens

UI for adding clients

Make it more intuitive when adding clients to the project, right now it is only possible to add one type of client.
A client can be many things, for now it should suffice to support 2 kinds of clients.

  1. Machine-to-machine-clients
  2. WebApp/Desktop-clients

A client model may look like this:

ClientId: Guid, Generated by backend
Enabled: Boolean, Default true
ClientSecrets: List of strings, For use with M-to-M
AllowedGrantTypes: Enum, M-to-M use ClientCredentials, WebApps/Desktop use Code with PKCE. (More to be added later)
RedirectUris: List of strings A list of allowed URIs to return tokens or authorization codes to
AllowedScopes: List of strings, Scopes (Api- or IdentityResources) this client has access to, default empty.
PostLogoutRedirectUris: List of strings, URIs that are allowed to redirect to.

Add admin user to docker environment

It should be possible to create an admin user when starting the project. This needs to happen from the outside using some suitable method. Otherwise the admin user needs to be created on the fly, outputting this to the user of the docker-image.

Add support for two-factor.

A login-service such as this should support two-factor. This will then trigger the need to support sms or YubiKey or something similar.

Add admin policy

Only the administrator should have access to adding users, clients and resources. Add policies to handle this.

Add e-mail sending service

When users are added it should be possible to send them a invite link they can use to set a password, to gain access.

Enpoints for users

It should be possible to get all users, update a user, delete a user and add a user.

Cannot start docker image on arm-based Mac

Following the instructions in the READMEs and doing
docker-compose up gives the following error:
seqsink_1 | Failed to create CoreCLR, HRESULT: 0x8007FF06
seqsink_1 | Failed to create CoreCLR, HRESULT: 0x8007FF06

And eventually:

docker_seqsink_1 exited with code 137
web_1      | [17:02:07 ERR] Could not initialize identity db after 5 attempts
web_1      | [17:02:07 WRN] Storing keys in a directory '/root/.aspnet/DataProtection-Keys' that may not be persisted outside of the container. Protected data will be unavailable when container is destroyed.
web_1      | [17:02:07 INF] User profile is available. Using '/root/.aspnet/DataProtection-Keys' as key repository; keys will not be encrypted at rest.
web_1      | [17:02:07 INF] Entity Framework Core 5.0.3 initialized 'ApplicationDbContext' using provider 'Pomelo.EntityFrameworkCore.MySql' with options: MaxPoolSize=128 ServerVersion 10.3.9-mariadb
web_1      | [17:02:07 ERR] An error occurred using the connection to database 'PowerDb' on server 'localhost'.
web_1      | [17:02:07 INF] A transient exception occurred during execution. The operation will be retried after 0ms.
web_1      | MySqlConnector.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts.
web_1      |    at MySqlConnector.Core.ServerSession.ConnectAsync(ConnectionSettings cs, Int32 startTickCount, ILoadBalancer loadBalancer, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ServerSession.cs:line 381
web_1      |    at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 110
web_1      |    at MySqlConnector.Core.ConnectionPool.GetSessionAsync(MySqlConnection connection, Int32 startTickCount, IOBehavior ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/Core/ConnectionPool.cs:line 140
web_1      |    at MySqlConnector.MySqlConnection.CreateSessionAsync(ConnectionPool pool, Int32 startTickCount, Nullable`1 ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/MySqlConnection.cs:line 846
web_1      |    at MySqlConnector.MySqlConnection.OpenAsync(Nullable`1 ioBehavior, CancellationToken cancellationToken) in /_/src/MySqlConnector/MySqlConnection.cs:line 410
web_1      |    at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenInternalAsync(Boolean errorsExpected, CancellationToken cancellationToken)
web_1      |    at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenInternalAsync(Boolean errorsExpected, CancellationToken cancellationToken)
web_1      |    at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenAsync(CancellationToken cancellationToken, Boolean errorsExpected)
web_1      |    at Pomelo.EntityFrameworkCore.MySql.Storage.Internal.MySqlRelationalConnection.OpenAsync(CancellationToken cancellationToken, Boolean errorsExpected)
web_1      |    at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteReaderAsync(RelationalCommandParameterObject parameterObject, CancellationToken cancellationToken)
web_1      |    at Microsoft.EntityFrameworkCore.Query.Internal.SingleQueryingEnumerable`1.AsyncEnumerator.InitializeReaderAsync(DbContext _, Boolean result, CancellationToken cancellationToken)
web_1      |    at Microsoft.EntityFrameworkCore.Storage.ExecutionStrategy.ExecuteImplementationAsync[TState,TResult](Func`4 operation, Func`4 verifySucceeded, TState state, CancellationToken cancellationToken)

Error 137 indicates a SIGKIll or out of memory conditions so I also tried to increase the memory for docker to 4GBs and swap space to 2GB

I found this issue
datalust/seq-tickets#1224
but I don't know if that is related.

My computer is:
MacBook Air (M1, 2020) with 8Gbs of memory.

UI for adding users

A user model should look like this:

Id: int, readonly for front end, used to lookup user
UserName: string, optional, the name of the user
Email: string, required, what is used as login
EmailConfirmed: boolean, default false
PhoneNumer: string, optional
PhoneNumberConfirmed: boolean, default false
TwoFactorEnabled: boolean, default false

Add UI to add Scopes to APIResources

It should be possible to add scopes to an APIResource, this is technically just a string, but it would be nice to have a UI-bit for this, as it is complex enough as it is. As a plus, having a ui for this, offers the option to explain some details to the user.

Update Readme for frontend

The readme file does not properly reflect how the frontend works, and how to get started when developing.

Trim the APIResourceDto, it has to much details right now.

This model should look like this:

Enabled: boolean, default true
Name: string, the name of the resource
DisplayName: string, can be used for consent screens
Description: string, can be used for consent screens
ApiSecrets: List of strings, used for token introspection, should be generated, and displayed once.
Scopes: List of string, comes from the APIScopes list, and should perhaps be added using UI, or as string

Enpoints for Scopes

It should be possible to get all scopes, add a scope, update a scope and delete a scope.

When deleting a scope it needs to be deleted from any Clients and ApiResources also affected by that scope.

Improve landing page

The landing page needs to be improved. Now you're just routed to the applications page

Enpoints for ApiResources

It should be possible to get all resources, add a resource, update a resource and delete a resource

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.