Skip to content

armgit / orca

Public Imported from GitHub
0

Orca is the place for working with a fleet of agents (e.g. Grok Bot, Claude Code). Run any coding agent with your own subscription. Available on desktop, mobile and remote runtime.

309 B
Raw Blame
import type { Stats } from 'node:fs'

export function isSafeOwnedDirectory(stats: Stats): boolean {
  if (!stats.isDirectory() || stats.isSymbolicLink()) {
    return false
  }
  return (
    typeof process.getuid !== 'function' ||
    (stats.uid === process.getuid() && (stats.mode & 0o777) === 0o700)
  )
}