You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| security | Map<string, [SecureAsset Object](#secure-asset-object)> | Object that desribes the authenticated scheme and href |
37
37
38
38
### Additional Field Information
39
39
40
40
#### security
41
41
42
42
An Asset property used to specify a keyword that defines the security level of the Asset.The most common values may be "private" or "public".
43
-
However, other keyword may be used to for alternative methods or levels of security.
43
+
However, other keyword may be used to for alternative methods or levels of security.
44
44
45
45
### Secure Asset Object
46
46
47
47
An Asset with the Secure Assets extension will have the following fields
48
48
49
-
| Field Name | Type | Description |
50
-
| ----------- | ------ | ----------- |
51
-
| scheme | string |**REQUIRED**. The authentification scheme used to access the data (`HttpClient`\|`S3Client`\|`PlanetaryComputerClient`\|`EarthdataClient`\|`SignedUrlClient`). |
52
-
| description | string | Additional instructions for authentification |
| scheme | string |**REQUIRED**. The authentification scheme used to access the data (`HttpClient`\|`S3Client`\|`PlanetaryComputerClient`\|`EarthdataClient`\|`SignedUrlClient`). |
52
+
| description | string | Additional instructions for authentification |
53
53
54
54
### Schemes
55
55
56
56
The authentification schemes align with the relevant clients included in the [stac-asset](https://github.com/stac-utils/stac-asset) library.
57
57
58
-
| Name | Description
59
-
| -- | -- |
60
-
|`HttpClient`| Simple HTTP client without any authentication |
61
-
| `S3Client` | Simple S3 client
62
-
| `PlanetaryComputerClient` | Signs URLs with the [Planetary Computer Authentication API](https://planetarycomputer.microsoft.com/docs/reference/sas/)
63
-
| `EarthdataClient` | Uses a token-based authentication to download data, from _some_ Earthdata providers, e.g. DAACs
64
-
| `SignedUrlClient` | Signs URLs with a user-defined Authentification API
|`HttpClient`| Simple HTTP client without any authentication|
61
+
|`S3Client`| Simple S3 client |
62
+
|`PlanetaryComputerClient`| Signs URLs with the [Planetary Computer Authentication API](https://planetarycomputer.microsoft.com/docs/reference/sas/)|
63
+
|`EarthdataClient`| Uses a token-based authentication to download data, from _some_ Earthdata providers, e.g. DAACs|
64
+
|`SignedUrlClient`| Signs URLs with a user-defined Authentification API|
65
65
66
66
### URL Signing
67
67
68
-
The `SignedUrlClient` scheme indicates that authentification will be handled by an API which generates and returns a signed URL. For example, a signed URL for assets in AWS S3 can be generated with the following Lambda function code.
68
+
The `SignedUrlClient` scheme indicates that authentification will be handled by an API which generates and returns a signed URL. For example,
69
+
a signed URL for assets in AWS S3 can be generated with the following Lambda function code.
69
70
70
71
```python
71
72
import boto3
@@ -94,7 +95,7 @@ The `SignedUrlClient` scheme indicates that authentification will be handled by
94
95
Params= {"Bucket": bucketName, "Key":key},
95
96
ExpiresIn=360
96
97
)
97
-
98
+
98
99
return ({
99
100
"statusCode": 200,
100
101
"body": json.dumps({
@@ -104,7 +105,7 @@ The `SignedUrlClient` scheme indicates that authentification will be handled by
104
105
"Access-Control-Allow-Origin": "*",
105
106
"Access-Control-Allow-Headers": "*"
106
107
}
107
-
108
+
108
109
})
109
110
exceptExceptionas e:
110
111
return {
@@ -114,41 +115,43 @@ The `SignedUrlClient` scheme indicates that authentification will be handled by
The authentication API can be called clientside using an AWS S3 href (`https://<bucket>.s3.<region>.amazonaws.com/<key>`) with the following code snippet.
127
+
The authentication API can be called clientside using an AWS S3 href (`https://<bucket>.s3.<region>.amazonaws.com/<key>`) with the following code
0 commit comments