Skip to content

Commit

Permalink
feat: deprecate MYINFO_APP_KEY (#557)
Browse files Browse the repository at this point in the history
  • Loading branch information
mantariksh authored Nov 4, 2020
1 parent 34705fc commit 7c56797
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 6 deletions.
1 change: 0 additions & 1 deletion docs/DEPLOYMENT_SETUP.md
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,6 @@ Note that MyInfo is currently not supported for storage mode forms and enabling
| `CP_IDP_CERT_PATH` | Path to National Digital Identity office's X.509 cert used for CorpPass related communication. |
| `MYINFO_CLIENT_CONFIG` | Configures [MyInfoGovClient](https://github.com/opengovsg/myinfo-gov-client). Set this to either`stg` or `prod` to fetch MyInfo data from the corresponding endpoints. |
| `MYINFO_FORMSG_KEY_PATH` | Filepath to MyInfo private key, which is used to decrypt returned responses. |
| `MYINFO_APP_KEY` | (deprecated) Directly specify contents of the MyInfo FormSG private key. Only works if `NODE_ENV` is set to `development`. |
| `IS_SP_MAINTENANCE` | If set, displays a banner message on SingPass forms. Overrides `IS_CP_MAINTENANCE`. |
| `IS_CP_MAINTENANCE` | If set, displays a banner message on CorpPass forms. |
| `FILE_SYSTEM_ID` | The id of the AWS Elastic File System (EFS) file system to mount onto the instances. |
Expand Down
5 changes: 0 additions & 5 deletions src/app/factories/spcp-myinfo.factory.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,11 +66,6 @@ const spcpFactory = ({ isEnabled, props }) => {
myInfoConfig.appId = myInfoPrefix + myInfoConfig.singpassEserviceId
myInfoConfig.mode = process.env.MYINFO_CLIENT_CONFIG
myInfoGovClient = new MyInfoGovClient(myInfoConfig)
} else if (config.isDev && process.env.MYINFO_APP_KEY) {
myInfoConfig.appId = 'STG2-' + myInfoConfig.singpassEserviceId
myInfoConfig.privateKey = process.env.MYINFO_APP_KEY
myInfoConfig.mode = 'stg'
myInfoGovClient = new MyInfoGovClient(myInfoConfig)
} else {
logger.warn({
message: `\n!!! WARNING !!!\nNo MyInfo keys detected.\nRequests to MyInfo will not work.\nThis should NEVER be seen in production.\nFalling back on MockPass.`,
Expand Down

0 comments on commit 7c56797

Please sign in to comment.