Apache Maka Security Considerations: Trust Model, Boundaries, and Best Practices
Apache Maka enforces security through OS user account boundaries, renderer process sandboxing, and managed tool sandboxes, while using heuristic permission prompts as non-enforced safety nets.
Apache Maka is a single-tenant personal desktop AI assistant designed to run inside the user’s own operating-system account. Understanding Apache Maka security considerations requires examining its clear separation between load-bearing (enforced) boundaries and heuristic safety nets that guide user behavior without guaranteeing protection.
Trust Model and Architecture Overview
The Apache Maka security architecture operates through distinct layers, each with specific trust characteristics. According to the repository’s Security Policy and Architecture Overview, the system distinguishes between components that serve as enforced boundaries versus those that rely on user discretion.
Component Layers and Security Boundaries
The trust model spans multiple layers from the agent process down to the OS kernel:
- Agent process (Electron main process and packages like
@maka/core,@maka/runtime,@maka/storage) – Executes all user-visible logic but does not constitute a load-bearing boundary; the OS remains the only enforced protection at this layer. - Renderer process – Runs within a sandboxed Chromium renderer communicating exclusively through the preload IPC bridge defined in
apps/desktop/src/preload/preload.ts. This IPC bridge serves as the trust envelope between renderer and main process. - Permission engine – Evaluates tool requests against
PERMISSION_POLICYand prompts users before destructive actions, though this remains a heuristic rather than a security guarantee. - Credential store – Stores OAuth tokens in
credentials.jsonunder the user’s workspace with directory permissions0o700and file permissions0o600, protected by the OS user account. - OS user account – The outermost trust envelope where all tools execute with the privileges of the logged-in user.
- Managed tool sandboxes – Seatbelt (macOS), bubblewrap (Linux), and AppContainer (Windows) enforce isolation for specific tool executions listed in §2.2 of the security policy.
Load-Bearing Security Boundaries in Apache Maka
Apache Maka implements several enforcement mechanisms that provide concrete security guarantees rather than mere suggestions.
OS User Account Isolation
The primary security boundary relies on the operating system user account. Users should run Maka under a non-admin account, ensuring that all file and network operations inherit restricted permissions. This boundary is documented in SECURITY.md sections 2.3 and 2.4.
Managed Tool Sandboxes
For commands requiring isolation—such as non-PTY Bash sessions or filesystem workers—Maka invokes OS-level sandboxes. These sandboxes operate on a fail-closed principle: if sandbox enforcement fails, the operation aborts rather than falling back to the host environment. The implementation details reside in packages/runtime/src/sandbox/README.md.
Credential Storage and IPC Masking
Sensitive credentials receive protection through filesystem permissions and IPC boundary controls:
- The
credentials.jsonfile stores OAuth tokens for Claude, Codex, GitHub Copilot, and xAI with strict0o600permissions. - Cleartext tokens never cross the main-to-renderer IPC boundary; the renderer only receives masked sentinels (
••••••). - The
maskAppSettingsfunction inapps/desktop/src/main/settings-ipc-helpers.tsmasks sensitive fields including API keys and proxy passwords at the IPC store boundary.
Renderer Process Sandbox
The Chromium renderer process cannot directly access the filesystem, network, or shell. All privileged actions must traverse IPC handlers defined in apps/desktop/src/main/main.ts. This architecture prevents renderer compromises from immediately accessing host resources.
Heuristic Safety Nets and UX Controls
Beyond enforced boundaries, Apache Maka includes several UX-level mitigations that slow down potentially risky actions without providing security guarantees:
- Permission engine (
@maka/core/permission) – Prompts users before destructive, file-write, or shell-unsafe actions, though adversarial LLMs could theoretically persuade users to approve malicious operations. redactSecrets()– Applies regex-based output sanitization before rendering text, though novel secret formats may evade detection.- URL allowlist (
normalizeSearchUrl()) – Filters non-HTTP(S) URLs from search results based on pattern matching rather than sandbox enforcement. - Default
PermissionMode.ask– Requires user confirmation for risky operations by default, though this constitutes a prompt layer rather than a security boundary. - WebSearch fail-closed chain – Returns generic error messages without exposing API keys, though malformed queries may still reach the network.
These heuristics are documented in section 2.4 of the Security Policy.
Privacy Commitments and Data Handling
Apache Maka maintains specific privacy guarantees regarding data locality and transmission:
- Local-only workspace – All session data, tool results, telemetry, and settings reside under
app.getPath('userData')with no cloud synchronization shipped by default. - No query string logging – The WebSearch tool scrubs
argsSummarybefore analytics hooks to prevent leaking search terms. - Incognito context – When
incognitoActiveis true, WebSearch aborts before any network request occurs. - Token boundary preservation – Cleartext tokens travel only from renderer to main process (e.g., via Settings input) but never reverse direction.
These commitments appear in section 2.5 of SECURITY.md.
Configuring Security Settings
Developers can inspect and configure Apache Maka’s security controls programmatically.
Setting Permission Mode to Ask
Configure the safest default behavior to prompt users before risky tool executions:
import { setPermissionMode, PERMISSION_MODES } from '@maka/core/permission';
// Enforce user prompts before any risky tool invocation
setPermissionMode(PERMISSION_MODES.ask);
Reference: The permission engine implementation resides in @maka/core/permission as described in the Security Policy.
Reading Credentials Safely
Access the credential store without exposing sensitive data to logs or the renderer:
import { readCredentials } from '@maka/storage';
// Returns parsed JSON; never logs contents to console
const creds = readCredentials();
if (creds?.claude?.apiKey) {
// Use internally; do NOT transmit to renderer or logs
doSomethingWithClaudeKey(creds.claude.apiKey);
}
The credential file location and 0o600 permissions are specified in SECURITY.md.
Verifying Sandbox Execution
Execute commands within OS-enforced sandboxes for restricted sessions:
import { execInSandbox } from '@maka/runtime/sandbox';
// Run bash command within Seatbelt, bubblewrap, or AppContainer
execInSandbox('ls -la /tmp')
.then(output => console.log(output))
.catch(err => console.error('Sandbox enforcement failed:', err));
Sandbox implementation details are available in packages/runtime/src/sandbox/README.md.
Summary
- OS user accounts provide the primary security boundary; run Maka under non-admin privileges.
- Managed sandboxes (Seatbelt, bubblewrap, AppContainer) enforce fail-closed isolation for specific tool executions.
- IPC masking and
maskAppSettingsprevent credential exposure across the renderer-main process boundary. - Renderer sandboxing restricts Chromium processes from direct filesystem or network access.
- Heuristic controls like the permission engine and
redactSecrets()offer UX safeguards but do not constitute enforced boundaries. - Privacy commitments ensure local-only data storage and incognito network controls.
Frequently Asked Questions
What is the primary security boundary in Apache Maka?
The OS user account serves as the outermost load-bearing boundary. All Apache Maka processes and tools execute with the privileges of the logged-in user, making account isolation the foundational security control. Additional boundaries include managed tool sandboxes and the renderer IPC bridge, but these operate within the context of the user account permissions.
Are API keys and credentials protected in Apache Maka?
Yes. Credentials store in credentials.json with filesystem permissions 0o600 (file) and 0o700 (directory), readable only by the owner. The maskAppSettings function in apps/desktop/src/main/settings-ipc-helpers.ts ensures that API keys and proxy passwords appear as masked sentinels in the renderer process, and cleartext tokens never traverse from main to renderer via IPC.
How does Apache Maka handle potentially dangerous tool executions?
Apache Maka employs a two-tier approach: enforced boundaries and heuristic prompts. Managed sandboxes (Seatbelt, bubblewrap, AppContainer) provide fail-closed isolation for specific tools, while the permission engine prompts users before destructive actions. However, the permission prompts constitute UX controls rather than security guarantees, as users might approve malicious requests.
Where should I report security vulnerabilities in Apache Maka?
Report vulnerabilities privately to security@maka.app or via private GitHub Security Advisory when available. Include the precise file location (e.g., apps/desktop/src/main/main.ts:120-145), OS and version details, and evidence that a load-bearing boundary defined in section 2.3 of the Security Policy was crossed. Public disclosure should only occur after coordinated disclosure with the maintainers.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →