(bucketName, xml)
| 28 | }; |
| 29 | |
| 30 | function getObjectLockConfigRequest(bucketName, xml) { |
| 31 | const request = { |
| 32 | bucketName, |
| 33 | headers: { |
| 34 | 'host': `${bucketName}.s3.amazonaws.com`, |
| 35 | 'x-amz-bucket-object-lock-enabled': 'true', |
| 36 | }, |
| 37 | url: '/?object-lock', |
| 38 | actionImplicitDenies: false, |
| 39 | }; |
| 40 | if (xml) { |
| 41 | request.post = xml; |
| 42 | } |
| 43 | return request; |
| 44 | } |
| 45 | |
| 46 | function getObjectLockXml(mode, type, time) { |
| 47 | const xml = { |
no outgoing calls
no test coverage detected