php-jwt
php-jwt copied to clipboard
ECDSA algo
Are there any current detailed descriptions?
I think we have the two ways to complete this ECDSA algorithm.
- Using the existed ECDSA package with PHP directly.
- Implement the ECDSA algorithm with PHP for this package.
we can go for 1 but the dependency should be optional and in suggestions.
@adhocore, thank you for your reply.
I finally found the following two ECDSA
PHP packages. The lists are as follows:
Which one do you want to prefer?
Thanks.
my thinking was to have a Signature
class that works with either of them (whichever is available)
but not having these packages as deps, but in suggests
Hey @peter279k 👋 (we know eachother from other OpenSource work), Hello @adhocore thanks for writing this.
Is ECDSA still wanted for this?
I noticed that currently you direct-bind to php functions. Perhaps one or more interfaces would make implementing this more easy?
We have decode
and encode
method verbs right? and then perhaps some optional, options data object. Perhaps a type of exception, which allows communication that an encode or decode has failed?
Your ideas about using composer suggested packages is a nice one. Maybe all the interface definitions could trap any errors from functions not existing and throw a nice exception to let ops / platform / dev team know what to do, or at least what is wrong without leaking the details of how we do any of the encryption / decryption?
I'm using this in a WordPress plugin due to the low number of files and broad PHP compatibility, so thanks for making that easy too.
Is ECDSA still wanted for this?
hi @Lewiscowles1986, maybe yes but not must-have
I noticed that currently you direct-bind to php functions. Perhaps one or more interfaces would make implementing this more easy?
yep it requires some broader change, i think we can have EJWT
class extend JWT
as a simpler way to support ECDSA.
above all this lib is meant for simplicity and ease of use for most of the use case.
In this case, I'll squeak the effort :wink: for now simplicity of deployment has me just pinning the algorithm and switching out shared keys.
closing for now