{"_id":"@cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin","name":"@cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin","dist-tags":{"latest":"0.9.3"},"versions":{"0.9.3":{"name":"@cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin","version":"0.9.3","description":"Hardhat plugin for @google-cloud/kms integration with ethers@v6 signer","main":"dist/index.js","types":"dist/index.d.ts","author":{"name":"cuonghx-gutech","email":"cuonghx@gu-tech.com"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/0xcuonghx/ethers-kms-signer.git"},"publishConfig":{"access":"public"},"devDependencies":{"@nomicfoundation/hardhat-ethers":"^3.0.5","@types/node":"18.17.6","ethers":"^6.11.1","hardhat":"^2.21.0","prettier":"2.8.8","ts-node":"10.9.1","typescript":"4.9.5"},"scripts":{"build":"tsc"},"dependencies":{"@cuonghx.gu-tech/ethers-gcp-kms-signer":"^0.9.0"},"_id":"@cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin@0.9.3","gitHead":"a7884b0cd7298af6cf6a2c797ce8c4cb6d515e37","bugs":{"url":"https://github.com/0xcuonghx/ethers-kms-signer/issues"},"homepage":"https://github.com/0xcuonghx/ethers-kms-signer#readme","_nodeVersion":"18.20.2","_npmVersion":"10.5.0","dist":{"integrity":"sha512-u/a3p08CNp1XW8JK0eqga0gvL21eEOBTKD9+TU446r91FOqeyEHuhLuWB8MnHEH5zxeJSknDlAXfJMOTLskVjA==","shasum":"d8c8531f0ad0721543efccad9e29b8fe6a73b3c9","tarball":"https://registry.npmjs.org/@cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin/-/hardhat-gcp-kms-signer-plugin-0.9.3.tgz","fileCount":6,"unpackedSize":3856,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICtvj2TIlTQ+am170wMV4lY5+tKPFT+D4GGfyZi0xUlaAiA0sHM/QhOTHz8bAdM3ao0Y89roqYovlStD+VJuxRc/Mw=="}]},"_npmUser":{"name":"cuonghx.gu-tech","email":"cuonghx@gu-tech.com"},"directories":{},"maintainers":[{"name":"cuonghx.gu-tech","email":"cuonghx@gu-tech.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/hardhat-gcp-kms-signer-plugin_0.9.3_1715768751321_0.2039515991968388"},"_hasShrinkwrap":false}},"time":{"created":"2024-05-15T10:25:51.234Z","0.9.3":"2024-05-15T10:25:51.469Z","modified":"2024-05-15T10:25:51.721Z"},"maintainers":[{"name":"cuonghx.gu-tech","email":"cuonghx@gu-tech.com"}],"description":"Hardhat plugin for @google-cloud/kms integration with ethers@v6 signer","homepage":"https://github.com/0xcuonghx/ethers-kms-signer#readme","repository":{"type":"git","url":"git+https://github.com/0xcuonghx/ethers-kms-signer.git"},"author":{"name":"cuonghx-gutech","email":"cuonghx@gu-tech.com"},"bugs":{"url":"https://github.com/0xcuonghx/ethers-kms-signer/issues"},"license":"MIT","readme":"# ethers-gcp-kms-signer\n\nHardhat plugin for @google-cloud/kms integration with ethers@v6 signer\n\n## Feature\n\n- ethers@v6 signer compatible\n- hardhat plugin\n\n## Install\n\n```sh\nnpm install @cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin\n```\n\nAnd add the following statement to your hardhat.config.js:\n\n```js\nrequire(\"@cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin\");\n```\n\nOr, if you are using TypeScript, add this to your hardhat.config.ts:\n\n```js\nimport \"@cuonghx.gu-tech/hardhat-gcp-kms-signer-plugin\";\n```\n\n## Usage\n\nProvide AWS KMS credentials\n\n```javascript\nconst config: HardhatUserConfig = {\n  solidity: {\n    version: \"0.8.19\",\n    settings: {\n      optimizer: {\n        enabled: true,\n        runs: 50,\n      },\n    },\n  },\n  networks: {\n    \"custom-network\": {\n      url: process.env.JOC_TESTNET_ENDPOINT_URL || \"\",\n      accounts:\n        process.env.PRIVATE_KEY !== undefined ? [process.env.PRIVATE_KEY] : [],\n      gasPrice: 107000000000,\n      gcpKmsConfigs: [\n        {\n          credentials: {\n            client_email: process.env.GCP_KMS_CLIENT_ID!,\n            private_key:  process.env.GCP_KMS_PRIVATE_KEY!,\n          },\n          projectId:  process.env.GCP_KMS_PROJECT_ID!,\n          locationId:  process.env.GCP_KMS_LOCATION_ID!,\n          keyRingId:  process.env.GCP_KMS_KEY_RING_ID!,\n          keyId:  process.env.GCP_KMS_KEY_ID!,\n          versionId:  process.env.GCP_KMS_VERSION_ID!,\n        },\n      ],\n    },\n  },\n};\n```\n\nUse signers\n\n```js\nconst [deployer] = await getKmsSigners();\nconst Factory = await ethers.getContractFactory(\"Contract\", deployer);\n```\n","readmeFilename":"README.md"}