3

作業中のアプリケーションでサンドボックスを有効にしようとしています。アプリケーションはファイル システムに大きく依存していますが、ユーザー ファイルを作成、保存、およびロードするために、ファイルをアプリ コンテナーの外部に配置する必要はありません。しかし、サンドボックスを有効にすることで、アプリにファイルを書き込むことができなくなりました。

とにかくそれを達成することはありますか?

void DeterminePaths(const string &a_arg0)
{
    string  s;
    FSRef   ref_num;
    char    str_path[1024];
    OSErr   e = noErr;

    e = FSFindFolder(kOnSystemDisk, kCurrentUserFolderType, false, &ref_num);
    e = FSRefMakePath(&ref_num, (UInt8*)str_path, 1024);
    s = string(str_path);

//Then I add on 's' the local directories for example s + "/silly_things"
}

<dict>
    <key>com.apple.security.app-sandbox</key>
    <true/>
    <key>com.apple.security.files.user-selected.read-write</key>
    <true/>
    <key>com.apple.security.network.client</key>
    <true/>
    <key>com.apple.security.network.server</key>
    <true/>
</dict>
4

0 に答える 0