Remember 2FA code
Open
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 4.8k
- Forks
- 182
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 1
Description
Would it be possible to utilize anisette data to remember the 2FA code and not prompt for it each time? It's pretty easy to get anisette on macOS with SIP/AMFI enabled, works even on macOS 14.0 RC.
#!/usr/bin/osascript -l JavaScript
ObjC.bindFunction('dlopen', ['void*', ['char*', 'int']]);
$.dlopen('/System/Library/PrivateFrameworks/AOSKit.framework/Versions/A/AOSKit', 0xa);
const AOSUtilities = $.NSClassFromString($.NSString.alloc.initWithUTF8String('AOSUtilities'));
const otp = AOSUtilities.retrieveOTPHeadersForDSID('-2');
JSON.stringify(ObjC.unwrap(otp.allKeys).reduce((o,k) => { o[ObjC.unwrap(k)] = ObjC.deepUnwrap(otp.valueForKey(k)); return o; }, {}));
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the existing 2FA prompt and reviewing how the provided macOS anisette OTP-header example could supply authentication data. Done means the tool can use anisette data to remember the 2FA code and no longer prompt on every use, with the behavior verified on macOS.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- macos, swift
- Domain
- authentication, cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100