# NfsExportOptions

- [JSON representation](https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#SCHEMA_REPRESENTATION)
- [AccessMode](https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#AccessMode)
- [SquashMode](https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#SquashMode)
- [SecurityFlavor](https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#SecurityFlavor)

NFS export options specifications.

| JSON representation |
|---|
| ``` { "ipRanges": [ string ], "accessMode": enum (`https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#AccessMode`), "squashMode": enum (`https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#SquashMode`), "anonUid": string, "anonGid": string, "securityFlavors": [ enum (`https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#SecurityFlavor`) ], "network": string } ``` |

| Fields ||
|---|---|
| `ipRanges[]` | `string` List of either an IPv4 addresses in the format `{octet1}.{octet2}.{octet3}.{octet4}` or CIDR ranges in the format `{octet1}.{octet2}.{octet3}.{octet4}/{mask size}` which may mount the file share. Overlapping IP ranges are not allowed, both within and across NfsExportOptions. An error will be returned. The limit is 64 IP ranges/addresses for each FileShareConfig among all NfsExportOptions. |
| `accessMode` | ``enum (`https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#AccessMode`)`` Either READ_ONLY, for allowing only read requests on the exported directory, or READ_WRITE, for allowing both read and write requests. The default is READ_WRITE. |
| `squashMode` | ``enum (`https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#SquashMode`)`` Either NO_ROOT_SQUASH, for allowing root access on the exported directory, or ROOT_SQUASH, for not allowing root access. The default is NO_ROOT_SQUASH. |
| `anonUid` | `string (https://developers.google.com/discovery/v1/type-format format)` An integer representing the anonymous user id with a default value of 65534. Anon_uid may only be set with squashMode of ROOT_SQUASH. An error will be returned if this field is specified for other squashMode settings. |
| `anonGid` | `string (https://developers.google.com/discovery/v1/type-format format)` An integer representing the anonymous group id with a default value of 65534. Anon_gid may only be set with squashMode of ROOT_SQUASH. An error will be returned if this field is specified for other squashMode settings. |
| `securityFlavors[]` | ``enum (`https://docs.cloud.google.com/filestore/docs/reference/rest/v1beta1/NfsExportOptions#SecurityFlavor`)`` The security flavors allowed for mount operations. The default is AUTH_SYS. |
| `network` | `string` Optional. The source VPC network for ipRanges. Required for instances using Private Service Connect, optional otherwise. If provided, must be the same network specified in the `NetworkConfig.network` field. |

## AccessMode

The access mode.

| Enums ||
|---|---|
| `ACCESS_MODE_UNSPECIFIED` | AccessMode not set. |
| `READ_ONLY` | The client can only read the file share. |
| `READ_WRITE` | The client can read and write the file share (default). |

## SquashMode

The squash mode.

| Enums ||
|---|---|
| `SQUASH_MODE_UNSPECIFIED` | SquashMode not set. |
| `NO_ROOT_SQUASH` | The Root user has root access to the file share (default). |
| `ROOT_SQUASH` | The Root user has squashed access to the anonymous uid/gid. |

## SecurityFlavor

The security flavor. In general, a "flavor" represents a designed process or system. A "security flavor" is a system designed for the purpose of authenticating a data originator (client), recipient (server), and the data they transmit between one another.

| Enums ||
|---|---|
| `SECURITY_FLAVOR_UNSPECIFIED` | SecurityFlavor not set. |
| `AUTH_SYS` | The user's UNIX user-id and group-ids are transferred "in the clear" (not encrypted) on the network, unauthenticated by the NFS server (default). |
| `KRB5` | End-user authentication through Kerberos V5. |
| `KRB5I` | krb5 plus integrity protection (data packets are tamper proof). |
| `KRB5P` | krb5i plus privacy protection (data packets are tamper proof and encrypted). |