{"id":29904283,"url":"https://github.com/errm/rdsauth","last_synced_at":"2025-08-01T17:39:07.645Z","repository":{"id":302880369,"uuid":"1013815840","full_name":"errm/rdsauth","owner":"errm","description":null,"archived":false,"fork":false,"pushed_at":"2025-07-04T15:05:31.000Z","size":7,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-07-04T15:49:41.694Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/errm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-04T14:07:17.000Z","updated_at":"2025-07-04T15:02:37.000Z","dependencies_parsed_at":"2025-07-04T15:49:47.666Z","dependency_job_id":"cec743c6-9b67-4add-aad6-9e76639f6b63","html_url":"https://github.com/errm/rdsauth","commit_stats":null,"previous_names":["errm/rdsauth"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/errm/rdsauth","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/errm%2Frdsauth","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/errm%2Frdsauth/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/errm%2Frdsauth/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/errm%2Frdsauth/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/errm","download_url":"https://codeload.github.com/errm/rdsauth/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/errm%2Frdsauth/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268269557,"owners_count":24223273,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-01T02:00:08.611Z","response_time":67,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-08-01T17:39:01.798Z","updated_at":"2025-08-01T17:39:07.631Z","avatar_url":"https://github.com/errm.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RDS IAM Token Authentication\n\n[![Go Reference](https://pkg.go.dev/badge/github.com/errm/rdsauth.svg)](https://pkg.go.dev/github.com/errm/rdsauth)\n[![CI](https://github.com/errm/rdsauth/actions/workflows/ci.yaml/badge.svg)](https://github.com/errm/rdsauth/actions/workflows/ci.yaml)\n\n* RDS IAM authentication tokens are valid for 15 minutes.\n* IAM database authentication throttles connections at 200 new connections per second.\n* Connections that use the same authentication token are not throttled. It is recommended that you reuse authentication tokens when possible.\n\n## Usage\n\n```go\nimport (\n\t\"database/sql\"\n\t\"github.com/aws/aws-sdk-go-v2/config\"\n\t\"github.com/go-sql-driver/mysql\"\n\trdsauth \"github.com/errm/rdsauth/mysql\"\n)\n\nfunc main() {\n\t// Load AWS configuration\n\tcfg, _ := config.LoadDefaultConfig(context.TODO())\n\n\t// Configure MySQL connection\n\tmysqlConfig := mysql.NewConfig()\n\tmysqlConfig.User = \"dbuser\"\n        mysqlConfig.Addr = \"db-instance.region.rds.amazonaws.com:3306\"\n        mysqlConfig.Net = \"tcp\"\n\n        // Register the token provider\n        mysqlConfig.Apply(mysql.BeforeConnect(rdsauth.TokenProvider(cfg, 60*time.Second)))\n\n        connector, _ := mysql.NewConnector(mysqlConfig)\n\n\t// Open database connection\n\tdb, _ := sql.OpenDB(connector)\n\tdefer db.Close()\n\terr := db.Ping()\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ferrm%2Frdsauth","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ferrm%2Frdsauth","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ferrm%2Frdsauth/lists"}