[experimental] program derived address assertion and type guard functions don't actually assert that the address is off the curve
assertIsProgramDerivedAddress and isProgramDerivedAddress don't actually check to see if the address is off the curve. All they do is validate the format of the tuple.
Someone could supply a regular on-curve address there and have those guards pass.
The job is to add in the off-curve check, and to write tests.
NOTE: This still does nothing to assert that the bump seed is the correct one given the address supplied. Thoughts?
Sure I can make that change. Both methods will become async functions but I don't think that's an issue (EDIT: It's an issue).
RE the bump: it's only valid in conjunction with an array of seeds so there would be no way to assert it's valid unless we require the seeds. Maybe that's the job for another helper method like verifyProgramDerivedAddress(pda, seeds)?
Both methods will become async functions but I don't think that's an issue.
🪦 https://github.com/microsoft/TypeScript/issues/37681#issuecomment-1650605236
Because there has been no activity on this issue for 7 days since it was closed, it has been automatically locked. Please open a new issue if it requires a follow up.