mirror of
https://github.com/maxgoedjen/secretive.git
synced 2026-03-06 09:47:22 +01:00
WIP
This commit is contained in:
@@ -36,9 +36,11 @@ class AppDelegate: NSObject, NSApplicationDelegate {
|
||||
Task {
|
||||
for await session in socketController.sessions {
|
||||
Task {
|
||||
let inputParser = SSHAgentInputParser()
|
||||
do {
|
||||
for await message in session.messages {
|
||||
let agentResponse = try await agent.handle(data: message, provenance: session.provenance)
|
||||
let request = try await inputParser.parse(data: message)
|
||||
let agentResponse = await agent.handle(request: request, provenance: session.provenance)
|
||||
try await session.write(agentResponse)
|
||||
}
|
||||
} catch {
|
||||
|
||||
10
Sources/SecretAgent/XPCInputParser.swift
Normal file
10
Sources/SecretAgent/XPCInputParser.swift
Normal file
@@ -0,0 +1,10 @@
|
||||
import Foundation
|
||||
import SecretAgentKit
|
||||
|
||||
struct XPCAgentInputParser: SSHAgentInputParserProtocol {
|
||||
|
||||
func parse(data: Data) async throws -> SSHAgent.Request {
|
||||
fatalError()
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user