You don't need to get the existing file info for setting a few fields, you can just call

```php
$view->putFileInfo($path, array('encrypted' => true, ....);
```