Differences From Artifact [6e9b955715]:
- File src/OFApplication.h — part of check-in [648522a4e6] at 2018-11-04 16:24:41 on branch trunk — OFSandbox: Add support for unveil() (user: js, size: 9041) [annotate] [blame] [check-ins using]
To Artifact [2092ccca9e]:
- File
src/OFApplication.h
— part of check-in
[e0c2e70f7b]
at
2018-11-11 22:30:21
on branch trunk
— OFApplication: Disallow using a different sandbox
While the active sandbox can be changed, a different sandbox must not be
activated. The reason for this is that allowing to activate a different
sandbox makes it impossible to track which paths have already been
unveiled. (user: js, size: 9653) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 | * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call * @ref activateSandboxForExecdProcesses, an `exec()`'d process does not have * its permissions restricted! * * @param sandbox The sandbox to activate */ + (void)activateSandbox: (OFSandbox *)sandbox; /*! * @brief Activates the specified sandbox for `exec()`'d processes of the * application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * `unveiledPaths` on the sandbox must *not* be empty, otherwise an * @ref OFInvalidArgumentException is raised. * * @param sandbox The sandbox to activate */ + (void)activateSandboxForExecdProcesses: (OFSandbox *)sandbox; #endif - (instancetype)init OF_UNAVAILABLE; | > > > > > > | 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 | * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call * @ref activateSandboxForExecdProcesses, an `exec()`'d process does not have * its permissions restricted! * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ + (void)activateSandbox: (OFSandbox *)sandbox; /*! * @brief Activates the specified sandbox for `exec()`'d processes of the * application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * `unveiledPaths` on the sandbox must *not* be empty, otherwise an * @ref OFInvalidArgumentException is raised. * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ + (void)activateSandboxForExecdProcesses: (OFSandbox *)sandbox; #endif - (instancetype)init OF_UNAVAILABLE; |
︙ | ︙ | |||
285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 | * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call * @ref activateSandboxForExecdProcesses, an `exec()`'d process does not have * its permissions restricted! * * @param sandbox The sandbox to activate */ - (void)activateSandbox: (OFSandbox *)sandbox; /*! * @brief Activates the specified sandbox for `exec()`'d processes of the * application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * `unveiledPaths` on the sandbox must *not* be empty, otherwise an * @ref OFInvalidArgumentException is raised. * * @param sandbox The sandbox to activate */ - (void)activateSandboxForExecdProcesses: (OFSandbox *)sandbox; #endif @end | > > > > > > | 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 | * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call * @ref activateSandboxForExecdProcesses, an `exec()`'d process does not have * its permissions restricted! * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ - (void)activateSandbox: (OFSandbox *)sandbox; /*! * @brief Activates the specified sandbox for `exec()`'d processes of the * application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * `unveiledPaths` on the sandbox must *not* be empty, otherwise an * @ref OFInvalidArgumentException is raised. * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ - (void)activateSandboxForExecdProcesses: (OFSandbox *)sandbox; #endif @end |
︙ | ︙ |