Commit e73d115
authored
Add IAM authentication support for ElastiCache and MemoryDB (#69)
* feat(auth): Add IAM authentication support for ElastiCache and MemoryDB
- Extend `valkey_glide_server_credentials_t` to support IAM authentication
- Add `valkey_glide_service_type_t` enum for ElastiCache and MemoryDB service types
- Create `valkey_glide_iam_config_t` struct to store IAM authentication configuration
- Implement new IAM authentication test suite in `tests/iam_auth_test.php`
- Add support for configuring IAM authentication with cluster name, region, and service type
- Include optional refresh interval for IAM credentials
Enables secure authentication for AWS ElastiCache and MemoryDB clusters using IAM roles and credentials.
Signed-off-by: affonsov <[email protected]>
* chore(submodule): Update valkey-glide submodule reference
- Bump valkey-glide submodule to latest commit
- Synchronize submodule pointer with upstream repository
- Ensures project is using most recent version of valkey-glide
Signed-off-by: affonsov <[email protected]>
* fix lint
Signed-off-by: affonsov <[email protected]>
* fix lint
Signed-off-by: affonsov <[email protected]>
* - Add new constants for IAM configuration options in ValkeyGlide class
- Update README.md with IAM authentication code examples
- Modify configuration example to demonstrate IAM authentication scenarios
- Add helper function `get_exception_ce_for_client_type()` in common.h for consistent error handling
- Enhance error handling for IAM authentication configuration
- Update example configuration to include IAM authentication notes and best practices
This feature enables secure authentication for AWS ElastiCache and MemoryDB using IAM credentials.
Signed-off-by: affonsov <[email protected]>
* missed some changes to use the constants
Signed-off-by: affonsov <[email protected]>
* fix lint
Signed-off-by: affonsov <[email protected]>
---------
Signed-off-by: affonsov <[email protected]>1 parent ca90649 commit e73d115
File tree
9 files changed
+651
-13
lines changed- examples/basic
- tests
9 files changed
+651
-13
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
255 | 255 | | |
256 | 256 | | |
257 | 257 | | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
258 | 293 | | |
259 | 294 | | |
260 | 295 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
66 | 78 | | |
67 | | - | |
68 | | - | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
69 | 82 | | |
70 | 83 | | |
71 | 84 | | |
| |||
76 | 89 | | |
77 | 90 | | |
78 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
79 | 100 | | |
80 | 101 | | |
81 | 102 | | |
| |||
219 | 240 | | |
220 | 241 | | |
221 | 242 | | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
222 | 248 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
192 | 192 | | |
193 | 193 | | |
194 | 194 | | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
195 | 260 | | |
196 | 261 | | |
197 | 262 | | |
| |||
393 | 458 | | |
394 | 459 | | |
395 | 460 | | |
396 | | - | |
397 | | - | |
398 | | - | |
399 | | - | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
400 | 466 | | |
401 | 467 | | |
0 commit comments