Skip to content

Enable LavaMoat for webapp background#11582

Closed
kumavis wants to merge 31 commits intodevelopfrom
lavamoat-webapp-bg2
Closed

Enable LavaMoat for webapp background#11582
kumavis wants to merge 31 commits intodevelopfrom
lavamoat-webapp-bg2

Conversation

@kumavis
Copy link
Copy Markdown
Member

@kumavis kumavis commented Jul 21, 2021

This enables 🌋 LavaMoat 🌋 protections in the webapp background process

status

  • prepare @lavamoat/lavapack runtime (non-cjs)
  • add and use @lavamoat/lavapack runtime for background
  • add lavamoat-browserify for policy auto generation
  • update build policy
  • create handy policy generation yarn script
  • add browserify policy override
  • fix lavapack runtime-cjs bug
  • patch or fix transforms to be minify-proof
  • fix e2e delays
  • e2e delays upstreamed first test/e2e - add longer timeouts #11667

previous draft PR: #10838

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [86211d4]
Page Load Metrics (659 ± 31 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint54876584
domContentLoaded5677906576531
load5687926596531
domInteractive5667906576531

@kumavis

This comment has been minimized.

@github-actions
Copy link
Copy Markdown
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@kumavis
Copy link
Copy Markdown
Member Author

kumavis commented Aug 2, 2021

error Command "lavamoat:debug" not found

@ryanml ryanml force-pushed the lavamoat-webapp-bg2 branch from 23c6996 to cb9bd66 Compare August 10, 2021 21:48
@ryanml ryanml force-pushed the lavamoat-webapp-bg2 branch from 874e9fb to 7370111 Compare August 10, 2021 22:14
@Gudahtt
Copy link
Copy Markdown
Member

Gudahtt commented Sep 3, 2021

In the test that was stalling, I added a few 5-second pauses each time the popup was opened to give time for it to finish loading. This seems to have gotten the tests un-stuck. I only added them in the failing test suite though - the pauses may be needed elsewhere as well.

It seems like the page load time is much longer on this branch. It takes a few seconds locally for the popup to get past the "grey rectangle" state.

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [ee9545c]
Page Load Metrics (460 ± 29 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint3875704535526
domContentLoaded3725484335325
load3905904606029
domInteractive3715484335325

@metamaskbot
Copy link
Copy Markdown
Collaborator

Builds ready [6c467ac]
Page Load Metrics (507 ± 40 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint9874348712058
domContentLoaded3737384838641
load3947485078340
domInteractive3737384838641

@kumavis
Copy link
Copy Markdown
Member Author

kumavis commented Sep 11, 2021

doing some QA:

  • perf seems fine
  • background packages are indeed sandboxed

@kumavis
Copy link
Copy Markdown
Member Author

kumavis commented Sep 13, 2021

guess ill go eat worms

@kumavis
Copy link
Copy Markdown
Member Author

kumavis commented Sep 29, 2021

moving to #12242

@kumavis kumavis closed this Sep 29, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Sep 29, 2021
@kumavis kumavis deleted the lavamoat-webapp-bg2 branch January 25, 2023 19:33
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants