diff --git a/CHANGELOG.md b/CHANGELOG.md index a88c6fd..7f35bf2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,16 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ## [Unreleased] +## [2.3.0] - 2017-11-20 +### Added +- Can now specify `require_mfa` (`'yes'` or `'no'`) when creating or updating + a user. + +## [2.2.1] - 2017-11-14 +### Fixed +- Updated error message when the list of trusted IP ranges is not an array to + include what the given trusted IP ranges was (including data type). + ## [2.2.0] - 2017-11-09 ### Added - Throw custom exception type when `mfaVerify` gets a `429 Too Many Requests` @@ -28,7 +38,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ### Added - Initial version of ID Broker API client. -[Unreleased]: https://github.com/silinternational/idp-id-broker-php-client/compare/2.2.0...HEAD +[Unreleased]: https://github.com/silinternational/idp-id-broker-php-client/compare/2.3.0...HEAD +[2.3.0]: https://github.com/silinternational/idp-id-broker-php-client/compare/2.2.1...2.3.0 +[2.2.1]: https://github.com/silinternational/idp-id-broker-php-client/compare/2.2.0...2.2.1 [2.2.0]: https://github.com/silinternational/idp-id-broker-php-client/compare/2.1.2...2.2.0 [0.2.1]: https://github.com/silinternational/idp-id-broker-php-client/compare/0.2.0...0.2.1 [0.2.0]: https://github.com/silinternational/idp-id-broker-php-client/compare/0.1.0...0.2.0 diff --git a/features/request/request.feature b/features/request/request.feature index 847eadd..a4c9069 100644 --- a/features/request/request.feature +++ b/features/request/request.feature @@ -58,6 +58,7 @@ Feature: Formatting requests for sending to the ID Broker API And I provide an "email" of "john_smith@example.com" And I provide a "locked" of "no" And I provide an "active" of "yes" + And I provide a "require_mfa" of "no" When I call createUser Then the method should be "POST" And the url should be "https://api.example.com/user" @@ -71,7 +72,8 @@ Feature: Formatting requests for sending to the ID Broker API "username": "john_smith", "email": "john_smith@example.com", "locked": "no", - "active": "yes" + "active": "yes", + "require_mfa": "no" } """ @@ -82,6 +84,7 @@ Feature: Formatting requests for sending to the ID Broker API And I provide a "display_name" of "Johnny" And I provide a "locked" of "yes" And I provide an "active" of "yes" + And I provide a "require_mfa" of "yes" When I call updateUser Then the method should be "PUT" And the url should be "https://api.example.com/user/12345" @@ -91,7 +94,8 @@ Feature: Formatting requests for sending to the ID Broker API { "display_name": "Johnny", "locked": "yes", - "active": "yes" + "active": "yes", + "require_mfa": "yes" } """ diff --git a/features/response/response.feature b/features/response/response.feature index a82db56..b83c653 100644 --- a/features/response/response.feature +++ b/features/response/response.feature @@ -29,7 +29,12 @@ Feature: Handling responses from the ID Broker API "username": "john_smith", "email": "john_smith@example.com", "active": "yes", - "locked": "no" + "locked": "no", + "mfa": { + "prompt": "no", + "nag": "yes", + "options": [] + } } """ When I call authenticate with the necessary data @@ -76,7 +81,12 @@ Feature: Handling responses from the ID Broker API "username": "john_smith", "email": "john_smith@example.com", "active": "yes", - "locked": "no" + "locked": "no", + "mfa": { + "prompt": "no", + "nag": "yes", + "options": [] + } } """ When I call getUser with the necessary data diff --git a/src/descriptions/id-broker-api.php b/src/descriptions/id-broker-api.php index 6e80048..d6a35d2 100644 --- a/src/descriptions/id-broker-api.php +++ b/src/descriptions/id-broker-api.php @@ -69,6 +69,12 @@ 'enum' => ['yes', 'no'], 'location' => 'json', ], + 'require_mfa' => [ + 'required' => false, + 'type' => 'string', + 'enum' => ['yes', 'no'], + 'location' => 'json', + ], ], ], 'deactivateUserInternal' => [ @@ -262,6 +268,12 @@ 'enum' => ['yes', 'no'], 'location' => 'json', ], + 'require_mfa' => [ + 'required' => false, + 'type' => 'string', + 'enum' => ['yes', 'no'], + 'location' => 'json', + ], ], ], ],