Skip to content

Commit

Permalink
fix: don't persist sign-in information in Epic web authentication web…
Browse files Browse the repository at this point in the history
…view
  • Loading branch information
vapidinfinity committed Nov 11, 2024
1 parent 272c8c8 commit 09041f5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions Mythic.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -789,7 +789,7 @@
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 3143;
CURRENT_PROJECT_VERSION = 3144;
DEAD_CODE_STRIPPING = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_ASSET_PATHS = "\"Mythic/Preview Content\"";
Expand Down Expand Up @@ -836,7 +836,7 @@
"CODE_SIGN_IDENTITY[sdk=macosx*]" = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 3143;
CURRENT_PROJECT_VERSION = 3144;
DEAD_CODE_STRIPPING = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEVELOPMENT_ASSET_PATHS = "\"Mythic/Preview Content\"";
Expand Down
2 changes: 1 addition & 1 deletion Mythic/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ class AppDelegate: NSObject, NSApplicationDelegate { // https://arc.net/l/quote/

extension AppDelegate: UNUserNotificationCenterDelegate {}

extension AppDelegate: SPUUpdaterDelegate {}
extension AppDelegate: SPUUpdaterDelegate {} // FIXME: nonfunctional

extension AppDelegate: SwordRPCDelegate {
func swordRPCDidConnect(_ rpc: SwordRPC) {
Expand Down
7 changes: 5 additions & 2 deletions Mythic/Views/Unified/Windows/EpicWebAuthView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ fileprivate struct EpicInterceptorWebView: NSViewRepresentable {

class Coordinator: NSObject, WKNavigationDelegate {
var parent: EpicInterceptorWebView
@State private var isLoading: Bool = false // Local state for loading
@State private var isLoading: Bool = false

init(parent: EpicInterceptorWebView) {
self.parent = parent
Expand Down Expand Up @@ -142,7 +142,10 @@ fileprivate struct EpicInterceptorWebView: NSViewRepresentable {
}

func makeNSView(context: Context) -> WKWebView {
let webView = WKWebView()
let config = WKWebViewConfiguration()
config.websiteDataStore = .nonPersistent() // don't persist user data

let webView = WKWebView(frame: .zero, configuration: config)
webView.navigationDelegate = context.coordinator
return webView
}
Expand Down

0 comments on commit 09041f5

Please sign in to comment.