-
Notifications
You must be signed in to change notification settings - Fork 208
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: jannyHou <[email protected]>
- Loading branch information
Showing
11 changed files
with
231 additions
and
140 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import {BindingKey} from '@loopback/context'; | ||
import {JWTAuthenticationService} from './services/JWT.authentication.service'; | ||
import {HashPassword} from './services/hash.password.bcryptjs'; | ||
import {JWTStrategy} from './authentication-strategies/JWT.strategy'; | ||
|
||
// Discussion point for reviewers: | ||
// What would be the good naming conversion for bindings? | ||
export namespace JWTAuthenticationBindings { | ||
export const STRATEGY = BindingKey.create<JWTStrategy>( | ||
'authentication.strategies.jwt.strategy', | ||
); | ||
export const SECRET = BindingKey.create<string>('authentication.jwt.secret'); | ||
export const SERVICE = BindingKey.create<JWTAuthenticationService>( | ||
'services.authentication.jwt.service', | ||
); | ||
} | ||
|
||
export namespace OtherServicesBindings { | ||
export const HASH_PASSWORD = BindingKey.create<HashPassword>( | ||
'services.hash_password', | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.