I state that I use ServiceStack to authenticate my services. My problem is the following I am developing two authentication methods via credentials and via API key. The implementation is correct but I would like some services to be authenticated through Credentials while other services through API key. Reading from documentation it seemed to me that I understood that it was enough to insert in the [Authenticate] attribute the provider parameter equal to the property Name of the reference Auth class (Credentials or API), getting [Authenticated ("apikey")] for example. Unfortunately, implementing the example above, if I authenticate with credentials, I can call the service while I would only like this service to be called via API key. Do you have any solutions? thanks a lot
Authentication with ServiceStack and more provider
179 Views Asked by Reiuz At
1
There are 1 best solutions below
Related Questions in AUTHENTICATION
- Authenticate Flask rest API
- Sends a personalised error message from the back-end to the front-end with Nuxt-auth
- How to connect Spotify PKCE Authorization Boilerplate to Login-Button in React
- Laravel SPA auth with Sanctum
- _supabaseClient__WEBPACK_IMPORTED_MODULE_1__.supabase.auth.signIn is not a function
- My openID Authentication return 'You must have either https wrappers or curl enabled.'
- How to detect the Minimization of Custom Chrome Tabs on Android?
- Wordpress redirect to homepage after successfully logged in
- How to modify the prebuilt UI of authentication in aws amplify version 6 in React Native
- Creating a login system for my website, navlist not working?
- Receiving 400 bad request on post when customer auth handler is used
- Creating Azure B2B login system with Vue.js frontend & Python Django backend
- Gradio chatbot: how to export individual conversation histories?
- Set-Cookie header not forwarded by nginx to the client
- git asking for authentication when auth.json is present while running composer update
Related Questions in SERVICE
- Why does Angular ^17 have problems with my modules, services, etc
- Problem with Android App background service stoping
- How to use interceptors with services in nestjs
- Exchange data between a Windows service and an application
- Unable to resolve service name to its IP inside kubernetes cluster
- Self Hosted Agent service startup getting failed on VM restart
- Linux service stops logging
- Disable/Enable OSB proxy service via WLST
- Write rows on destination even when an error occurs?
- paho mqtt java cannot reconnect after a long time machine sleep
- IServiceCollectionConfigurator' does not contain a definition for 'UsingRabbitMq'
- "setOngoing(true)" Notification dismissed by user
- How to run powershell command in OnStart of ServiceBase Class in C#?
- Is there any way to globally override Android's back button click?
- Terraform Azure Provider: Authenticating using a Service Principal with a Client Certificate
Related Questions in SERVICESTACK
- Disable BasicAuth fallback
- ServiceStack.Redis Timeout with PooledRedisClientManager.IdleTimeOutSecs
- Unable to pass RBAC username of AWS Redis in ServiceStack,Redis. Does ServiceStack.Redis supports RBAC?
- ServiceStack with Windows Auth
- ServiceStack Admin UI respinse not visible
- Using Redis as SessionState store for ASP.NET MVC application on .net 4.8
- Typescript Generation explicitly adds inherited properties to inheriting class after updating to 8.1.2
- Query on C# ASP.NET Core Web App (Model-View-Controller)
- IDX11020: The JSON value of type: 'Number', could not be converted to 'JsonTokenType.String'. Reading: System.IdentityModel.Tokens.Jwt.JwtPayload.jti
- Is there a way to limit DTOs returned back from /types/typescript?
- ServiceStack Proxy returns 200 but doesn't hit server
- How can we use MySql Select Case construct in ORMLite ServiceStack
- Using ServiceStack, is it possible to create Derived Request class?
- Overriding ExecuteAsync on AuthenticateAttribute using Servicestack OrmLite
- How to avoid a ServiceStack API Explorer DTO binding error for a GET request when some of the form inputs are null
Related Questions in SERVICESTACK-AUTH
- How can we generate a jwt bearertoken on ServiceStack client side to impersonate a user?
- Why does UserAuthExtensions.PopulateFromMap(session, jwtPayload) does not deserialize json values with escape correctly in ServiceStack.Auth?
- UserAuthRole created even if UseDistinctRoleTables is false
- Using JwtAuthProviderReader with ServiceStack and AWS Cognito
- How to authenticate to a ServiceStack API which is part of a .Net 5 Identity MVC Website
- Error trying to resolve Service 'System.Boolean' from Adapter 'NetCoreContainerAdapter'
- Getting 403 forbidden with valid API key
- ServiceStack ServiceClient stores wrong cookies after authentication
- Authentication with ServiceStack and more provider
- ArgumentNullException with custom auth provider in ServiceStack
- How to redirect to a post upon authentication in ServiceStack
- How to authorise React/TypeScript application with ServiceStack and AAD
- How to implement Auth0 authentication in ServiceStack?
- ServiceStack and Auth0
- ServiceStack: AuthUser vs IAuthSession - how do I retrieve the AuthUser?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
The
[Authenticate(provider)]will check if the User is considered to be authenticated according to that Auth Provider where it calls the AuthProvidersIsAuthorized()to verify if the session is authenticated.If you want to mandate that a Request was authenticated using an API Key you can check for it in your Service implementation, e.g: