Skip to content

bind operation not permitted #292

Description

@nicholascross

I just ran in to a problem trying to embed the http server into a macos application.

It would fail to bind on any ip address the solution was not straight forward to locate for someone not experienced with such things, so I thought I would share it here in case others face it in the future.

To resolve you must update your apps entitlements file with the following

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>com.apple.security.app-sandbox</key>
    <false/>
    <key>com.apple.security.files.user-selected.read-only</key>
    <false/>
</dict>
</plist>

These will be true by default.

I found the solution here

If there are any better solutions please share!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions