Extensions
Legacy Authentication Scheme
To be able to read or write from S3, the correct region should be set:  
```sql
SET s3_region = 'us-east-1';
```  
Optionally, the endpoint can be configured in case a non-AWS object storage server is used:  
```sql
SET s3_endpoint = '⟨domain⟩.⟨tld⟩:⟨port⟩';
```  
If the endpoint is not SSL-enabled then run:  
```sql
SET s3_use_ssl = false;
```  
Switching between [path-style](https://docs.aws.amazon.com/AmazonS3/latest/userguide/VirtualHosting.html#path-style-access) and [vhost-style](https://docs.aws.amazon.com/AmazonS3/latest/userguide/VirtualHosting.html#virtual-hosted-style-access) URLs is possible using:  
```sql
SET s3_url_style = 'path';
```  
However, note that this may also require updating the endpoint. For example for AWS S3 it is required to change the endpoint to `s3.⟨region⟩.amazonaws.com`.  
After configuring the correct endpoint and region, public files can be read. To also read private files, authentication credentials can be added:  
```sql
SET s3_access_key_id = '⟨AWS access key id⟩';
SET s3_secret_access_key = '⟨AWS secret access key⟩';
```  
Alternatively, session tokens are also supported and can be used instead:  
```sql
SET s3_session_token = '⟨AWS session token⟩';
```  
The [`aws` extension](#docs:extensions:aws) allows for loading AWS credentials.