@aws-sdk/credential-provider-ini 3.0.0 → 3.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,47 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [3.4.1](https://github.com/aws/aws-sdk-js-v3/compare/v3.4.0...v3.4.1) (2021-01-29)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **clients:** use TS 3.4 compatible types for TS 3.9 ([#1978](https://github.com/aws/aws-sdk-js-v3/issues/1978)) ([8bced5c](https://github.com/aws/aws-sdk-js-v3/commit/8bced5c32b9dbc68f1065054d796cb0b8b87bcc4))
12
+
13
+
14
+
15
+
16
+
17
+ # [3.4.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.3.0...v3.4.0) (2021-01-28)
18
+
19
+
20
+ ### Features
21
+
22
+ * use downlevel-dts to generate TS 3.4 compatible types ([#1943](https://github.com/aws/aws-sdk-js-v3/issues/1943)) ([63ad215](https://github.com/aws/aws-sdk-js-v3/commit/63ad2151c8bb7be32ea8838a9b0974806ed3906b))
23
+
24
+
25
+
26
+
27
+
28
+ # [3.3.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.2.0...v3.3.0) (2021-01-14)
29
+
30
+
31
+ ### Bug Fixes
32
+
33
+ * **clients:** export explicit dependencies on @aws-sdk/types ([#1902](https://github.com/aws/aws-sdk-js-v3/issues/1902)) ([96f1087](https://github.com/aws/aws-sdk-js-v3/commit/96f1087333ba916593d557051297983912b27caa))
34
+
35
+
36
+
37
+
38
+
39
+ # [3.1.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.0.0...v3.1.0) (2020-12-23)
40
+
41
+ **Note:** Version bump only for package @aws-sdk/credential-provider-ini
42
+
43
+
44
+
45
+
46
+
6
47
  # [3.0.0](https://github.com/aws/aws-sdk-js-v3/compare/v1.0.0-rc.10...v3.0.0) (2020-12-15)
7
48
 
8
49
 
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @aws-sdk/credential-provider-ini
2
2
 
3
- [![NPM version](https://img.shields.io/npm/v/@aws-sdk/credential-provider-ini/rc.svg)](https://www.npmjs.com/package/@aws-sdk/credential-provider-ini)
3
+ [![NPM version](https://img.shields.io/npm/v/@aws-sdk/credential-provider-ini/latest.svg)](https://www.npmjs.com/package/@aws-sdk/credential-provider-ini)
4
4
  [![NPM downloads](https://img.shields.io/npm/dm/@aws-sdk/credential-provider-ini.svg)](https://www.npmjs.com/package/@aws-sdk/credential-provider-ini)
5
5
 
6
6
  ## AWS Credential Provider for Node.JS - Shared Configuration Files
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aws-sdk/credential-provider-ini",
3
- "version": "3.0.0",
3
+ "version": "3.4.1",
4
4
  "description": "AWS credential provider that sources credentials from ~/.aws/credentials and ~/.aws/config",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/es/index.js",
@@ -10,6 +10,7 @@
10
10
  "build:cjs": "tsc -p tsconfig.cjs.json",
11
11
  "build:es": "tsc -p tsconfig.es.json",
12
12
  "build": "yarn build:es && yarn build:cjs",
13
+ "postbuild": "downlevel-dts types types/ts3.4",
13
14
  "test": "jest"
14
15
  },
15
16
  "keywords": [
@@ -22,21 +23,28 @@
22
23
  },
23
24
  "license": "Apache-2.0",
24
25
  "dependencies": {
25
- "@aws-sdk/property-provider": "3.0.0",
26
- "@aws-sdk/shared-ini-file-loader": "3.0.0",
26
+ "@aws-sdk/property-provider": "3.4.1",
27
+ "@aws-sdk/shared-ini-file-loader": "3.4.1",
28
+ "@aws-sdk/types": "3.4.1",
27
29
  "tslib": "^1.8.0"
28
30
  },
29
31
  "devDependencies": {
30
- "@aws-sdk/types": "3.0.0",
31
32
  "@types/jest": "^26.0.4",
32
33
  "@types/node": "^10.0.0",
33
34
  "jest": "^26.1.0",
34
35
  "typescript": "~4.1.2"
35
36
  },
36
- "types": "./dist/cjs/index.d.ts",
37
+ "types": "./types/index.d.ts",
37
38
  "engines": {
38
39
  "node": ">= 10.0.0"
39
40
  },
41
+ "typesVersions": {
42
+ "<4.0": {
43
+ "types/*": [
44
+ "types/ts3.4/*"
45
+ ]
46
+ }
47
+ },
40
48
  "homepage": "https://github.com/aws/aws-sdk-js-v3/tree/master/packages/credential-provider-ini",
41
49
  "repository": {
42
50
  "type": "git",
package/tsconfig.cjs.json CHANGED
@@ -1,5 +1,6 @@
1
1
  {
2
2
  "compilerOptions": {
3
+ "declarationDir": "./types",
3
4
  "rootDir": "./src",
4
5
  "outDir": "./dist/cjs",
5
6
  "baseUrl": "."
package/tsconfig.es.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "compilerOptions": {
3
3
  "lib": ["es5", "es2015.promise", "es2015.collection"],
4
+ "declarationDir": "./types",
4
5
  "rootDir": "./src",
5
6
  "outDir": "./dist/es",
6
7
  "baseUrl": "."
File without changes
@@ -1,66 +1,66 @@
1
- import { ParsedIniData, SharedConfigFiles, SharedConfigInit } from "@aws-sdk/shared-ini-file-loader";
2
- import { CredentialProvider, Credentials } from "@aws-sdk/types";
3
- export declare const ENV_PROFILE = "AWS_PROFILE";
4
- /**
5
- * @see http://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/STS.html#assumeRole-property
6
- * TODO update the above to link to V3 docs
7
- */
8
- export interface AssumeRoleParams {
9
- /**
10
- * The identifier of the role to be assumed.
11
- */
12
- RoleArn: string;
13
- /**
14
- * A name for the assumed role session.
15
- */
16
- RoleSessionName: string;
17
- /**
18
- * A unique identifier that is used by third parties when assuming roles in
19
- * their customers' accounts.
20
- */
21
- ExternalId?: string;
22
- /**
23
- * The identification number of the MFA device that is associated with the
24
- * user who is making the `AssumeRole` call.
25
- */
26
- SerialNumber?: string;
27
- /**
28
- * The value provided by the MFA device.
29
- */
30
- TokenCode?: string;
31
- }
32
- export interface FromIniInit extends SharedConfigInit {
33
- /**
34
- * The configuration profile to use.
35
- */
36
- profile?: string;
37
- /**
38
- * A promise that will be resolved with loaded and parsed credentials files.
39
- * Used to avoid loading shared config files multiple times.
40
- */
41
- loadedConfig?: Promise<SharedConfigFiles>;
42
- /**
43
- * A function that returna a promise fulfilled with an MFA token code for
44
- * the provided MFA Serial code. If a profile requires an MFA code and
45
- * `mfaCodeProvider` is not a valid function, the credential provider
46
- * promise will be rejected.
47
- *
48
- * @param mfaSerial The serial code of the MFA device specified.
49
- */
50
- mfaCodeProvider?: (mfaSerial: string) => Promise<string>;
51
- /**
52
- * A function that assumes a role and returns a promise fulfilled with
53
- * credentials for the assumed role.
54
- *
55
- * @param sourceCreds The credentials with which to assume a role.
56
- * @param params
57
- */
58
- roleAssumer?: (sourceCreds: Credentials, params: AssumeRoleParams) => Promise<Credentials>;
59
- }
60
- /**
61
- * Creates a credential provider that will read from ini files and supports
62
- * role assumption and multi-factor authentication.
63
- */
64
- export declare function fromIni(init?: FromIniInit): CredentialProvider;
65
- export declare function getMasterProfileName(init: FromIniInit): string;
66
- export declare function parseKnownFiles(init: FromIniInit): Promise<ParsedIniData>;
1
+ import { ParsedIniData, SharedConfigFiles, SharedConfigInit } from "@aws-sdk/shared-ini-file-loader";
2
+ import { CredentialProvider, Credentials } from "@aws-sdk/types";
3
+ export declare const ENV_PROFILE = "AWS_PROFILE";
4
+ /**
5
+ * @see http://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/STS.html#assumeRole-property
6
+ * TODO update the above to link to V3 docs
7
+ */
8
+ export interface AssumeRoleParams {
9
+ /**
10
+ * The identifier of the role to be assumed.
11
+ */
12
+ RoleArn: string;
13
+ /**
14
+ * A name for the assumed role session.
15
+ */
16
+ RoleSessionName: string;
17
+ /**
18
+ * A unique identifier that is used by third parties when assuming roles in
19
+ * their customers' accounts.
20
+ */
21
+ ExternalId?: string;
22
+ /**
23
+ * The identification number of the MFA device that is associated with the
24
+ * user who is making the `AssumeRole` call.
25
+ */
26
+ SerialNumber?: string;
27
+ /**
28
+ * The value provided by the MFA device.
29
+ */
30
+ TokenCode?: string;
31
+ }
32
+ export interface FromIniInit extends SharedConfigInit {
33
+ /**
34
+ * The configuration profile to use.
35
+ */
36
+ profile?: string;
37
+ /**
38
+ * A promise that will be resolved with loaded and parsed credentials files.
39
+ * Used to avoid loading shared config files multiple times.
40
+ */
41
+ loadedConfig?: Promise<SharedConfigFiles>;
42
+ /**
43
+ * A function that returna a promise fulfilled with an MFA token code for
44
+ * the provided MFA Serial code. If a profile requires an MFA code and
45
+ * `mfaCodeProvider` is not a valid function, the credential provider
46
+ * promise will be rejected.
47
+ *
48
+ * @param mfaSerial The serial code of the MFA device specified.
49
+ */
50
+ mfaCodeProvider?: (mfaSerial: string) => Promise<string>;
51
+ /**
52
+ * A function that assumes a role and returns a promise fulfilled with
53
+ * credentials for the assumed role.
54
+ *
55
+ * @param sourceCreds The credentials with which to assume a role.
56
+ * @param params
57
+ */
58
+ roleAssumer?: (sourceCreds: Credentials, params: AssumeRoleParams) => Promise<Credentials>;
59
+ }
60
+ /**
61
+ * Creates a credential provider that will read from ini files and supports
62
+ * role assumption and multi-factor authentication.
63
+ */
64
+ export declare function fromIni(init?: FromIniInit): CredentialProvider;
65
+ export declare function getMasterProfileName(init: FromIniInit): string;
66
+ export declare function parseKnownFiles(init: FromIniInit): Promise<ParsedIniData>;