-
Notifications
You must be signed in to change notification settings - Fork 893
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Email aliases implementation #27127
base: master
Are you sure you want to change the base?
Email aliases implementation #27127
Conversation
(Not we are using a temporary Brave API Key; we will use the real one programmatically once the backend is ready to use it.) |
[puLL-Merge] - brave/brave-core@27127 DescriptionThis PR introduces a new Email Aliases feature to the Brave browser. It adds functionality for users to create, manage, and use email aliases to protect their primary email address. The feature includes a new settings page, a bubble UI for quick alias creation, and integration with Brave's existing systems. Possible Issues
Security Hotspots
ChangesChanges
sequenceDiagram
User->>BraveUI: Clicks "Email Aliases" in settings
BraveUI->>EmailAliasesHandler: Load Email Aliases page
EmailAliasesHandler->>MappingService: Get account email
MappingService->>EmailAliasesHandler: Return account email
EmailAliasesHandler->>BraveUI: Display Email Aliases page
User->>BraveUI: Creates new alias
BraveUI->>EmailAliasesHandler: Create new alias request
EmailAliasesHandler->>MappingService: Generate new alias
MappingService->>ExternalService: API call to create alias
ExternalService->>MappingService: Confirm alias creation
MappingService->>EmailAliasesHandler: Return new alias
EmailAliasesHandler->>BraveUI: Update UI with new alias
BraveUI->>User: Display confirmation
|
@@ -493,6 +494,8 @@ void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) { | |||
base::Value(false)); | |||
|
|||
webcompat_reporter::prefs::RegisterProfilePrefs(registry); | |||
|
|||
email_aliases::RegisterProfilePrefs(registry); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's the use of these prefs here for? I'm curious if you think it would be useful to integrity protect them to prevent filesystem tampering here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking at what's set in here, yeah let's integrity protect them: https://github.com/brave/brave-core/pull/27127/files#diff-398d0bffbf3c145bfd429720571b80c331b23abf384570fc0403a493bae06a9aR19-R23
The way to do this is by using a "tracked preference" - https://source.chromium.org/chromium/chromium/src/+/main:services/preferences/tracked/
ui::SimpleMenuModel* autofill_menu_model = | ||
static_cast<ui::SimpleMenuModel*>(GetSubmenuModelAt( | ||
GetIndexOfCommandId(IDC_PASSWORDS_AND_AUTOFILL_MENU).value())); | ||
DCHECK(autofill_menu_model); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it an issue if this var doesn't get set? Thinking CHECK or error handling with a nil return might be better here if so instead of DCHECK which I believe gets optimized out at build time unless it's a debug build
@arthuredelstein is this one ready for review? Can you link a spec please? |
Resolves brave/brave-browser#43115
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
wikinpm run presubmit
wiki,npm run gn_check
,npm run tslint
git rebase master
(if needed)Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on
Test Plan: