Skip to content

Unknown process connections due to missing /proc/pid/task parsing #343

@AlexFromChaos

Description

@AlexFromChaos

Currently in some situations (like multi-process Firefox/Chrome instances) OpenSnitch fails to determine process' PID from inode as the connection originating from a child process, whose PID entry is at /proc/<parent_PID>/task/<PID>, not /proc/<PID>.

Because of this, per-process rules cannot be applied to many connections from apps like Firefox/Chrome.

Is there some legitimate reason why we can't do /proc/pid/task parsing?

The comment in code says:

// lookupPidInProc searches for an inode in /proc.
// First it gets the running PIDs and obtains the opened sockets.
// TODO: If the inode is not found, search again in the task/threads
// of every PID (costly).

The question is, does it slow down things so badly? Perhaps allowing user to manually enable it via settings might be a good solution if so.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions