Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/SoFriendly/2fhey
https://github.com/SoFriendly/2fhey
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/SoFriendly/2fhey
- Owner: SoFriendly
- License: cc0-1.0
- Created: 2022-04-28T21:52:29.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-03-20T18:57:15.000Z (3 months ago)
- Last Synced: 2024-03-21T19:59:08.760Z (3 months ago)
- Language: Swift
- Size: 4.29 MB
- Stars: 87
- Watchers: 6
- Forks: 22
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Lists
- awesome-macOS - 2FHey - iMessage AutoFill For Any Browser. Auto-copy 2FA & OTP codes into Firefox & Google Chrome (Uncategorized / Uncategorized)
- my-awesome-stars - SoFriendly/2fhey - (Swift)
README
## Adding Custom Patterns
If a code for a service you use isn't automatically detected with the built-in pattern matchers, you can create a PR to add a custom pattern. In `AppConfig.json`, there is a key called `customPatterns`. A `customPatterns` object must be in the format:
```
{
"serviceName": "the name of the service that uses this format",
"matcherPattern": "a regex pattern to determine if a text belongs to this service",
"codeExtractorPattern": "a regex pattern used to match the OTP code from a message"
}
```For example, if a service sent a text that looked like:
```
someweird-pattern:a1b2c3
```where `a1b2c3` is the code we want to be parsed, we could an entry that looks like:
```
{
"serviceName": "some service",
"matcherPattern": "^someweird-.+$",
"codeExtractorPattern": "^someweird.+:((\\d|\\D){4,6})$"
}
```