# HDFS access control

To prevent Hadoop Distributed File System (HDFS) from using non-secured access types (such as HTTP unencrypted protocol or local files), you need to edit a configuration file in your Remote Engine Gen2 installation.

## Procedure

1. Go to the Remote Engine Gen2 installation directory.
2. Open the default/docker-compose.yml file to edit it.
3. Find the following parameters in the service named livy and make sure their values are set to false.
   ```
   livy:
   	...
   	environment:
   		...
   		CONNECTORS_ENABLE_NON_SECURED_ACCESS: "false"
   		CONNECTORS_ENABLE_LOCAL_NETWORK_ACCESS: "false"
   ```

   Setting the value of one of these parameters to false will result in allowing only secured protocols:
   * CONNECTORS\_ENABLE\_NON\_SECURED\_ACCESS: "false" will prevent the HDFS connector from accepting unencrypted protocols.
   * CONNECTORS\_ENABLE\_LOCAL\_NETWORK\_ACCESS: "false" will prevent the HDFS connector from accepting local files (File is Blocked; HDFS or webHDFS works).
4. In the same file, look for the same parameters in the services named previewrunner and component-server and change their values to false as well.
5. Save your changes and close the file.
6. Restart the engine to take these changes into account.