Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[3.x] feat: allow to customise the signature_method #78

Merged
merged 2 commits into from
May 1, 2023
Merged

[3.x] feat: allow to customise the signature_method #78

merged 2 commits into from
May 1, 2023

Conversation

ankurk91
Copy link
Contributor

@ankurk91 ankurk91 commented Apr 30, 2023

Hi,

Vonage allows us to customise the signature method (algo) through their dashboard (see screenshot), the default value is set to HMAC_SHA256.

This package was hard coded to use md5hash, this PR introduce a new config key signature_method which allows us to override the parameter.
Web capture_30-4-2023_10815_dashboard nexmo com

Vonage uses this algorithm to sign the incoming webhooks as well as outgoing SMS via the SDK.

PS.
I have kept backward compatibility, the default algo in sdk is still the same.

@@ -22,8 +22,6 @@ public function register()
$this->app->singleton(Client::class, function ($app) {
$config = $app['config']['vonage'];

$httpClient = null;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line was unused always since the variable is being initialised in the very next line.

This change is not related to the new feature introduced .

@taylorotwell taylorotwell merged commit 9423dbd into laravel:3.x May 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants