AWS RDS SSL certificates bundles.
npm install aws-ssl-profilesAWS RDS SSL Certificates Bundles.
Table of Contents
- Installation
- Usage
- mysqljs/mysql
- MySQL2
- node-postgres
- Custom ssl options
- License
- Security
- Contributing
- Acknowledgements
---
``bash`
npm install --save aws-ssl-profiles
---
`js
const mysql = require('mysql');
const awsCaBundle = require('aws-ssl-profiles');
// mysql connection
const connection = mysql.createConnection({
//...
ssl: awsCaBundle,
});
// mysql connection pool
const pool = mysql.createPool({
//...
ssl: awsCaBundle,
});
`
`js
const mysql = require('mysql2');
const awsCaBundle = require('aws-ssl-profiles');
// mysql2 connection
const connection = mysql.createConnection({
//...
ssl: awsCaBundle,
});
// mysql2 connection pool
const pool = mysql.createPool({
//...
ssl: awsCaBundle,
});
`
`js
const pg = require('pg');
const awsCaBundle = require('aws-ssl-profiles');
// pg connection
const client = new pg.Client({
// ...
ssl: awsCaBundle,
});
// pg connection pool
const pool = new pg.Pool({
// ...
ssl: awsCaBundle,
});
`
Using AWS SSL Profiles with custom ssl options:
`js`
{
// ...
ssl: {
...awsCaBundle,
rejectUnauthorized: true,
// ...
}
}
`js`
{
// ...
ssl: {
ca: awsCaBundle.ca,
rejectUnauthorized: true,
// ...
}
}
`js
const { proxyBundle } = require('aws-ssl-profiles');
{
// ...
ssl: proxyBundle,
}
``
---
AWS SSL Profiles is under the MIT License.
---
Please check the SECURITY.md.
---
Please check the CONTRIBUTING.md for instructions.
---