Skip to content

Commit

Permalink
fix: use safe_deserialize
Browse files Browse the repository at this point in the history
  • Loading branch information
jatZama committed Oct 22, 2024
1 parent d6824e8 commit 8768499
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/sdk/network.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ export const getKeysFromGateway = async (url: string) => {
const crsUrl = data.response.crs['2048'].urls[0];
const crs2048 = await await fetch(crsUrl);
return {
publicKey: TfheCompactPublicKey.deserialize(publicKey),
publicKey: TfheCompactPublicKey.safe_deserialize(publicKey, 80_000),
publicParams: {
2048: CompactPkePublicParams.deserialize(crs2048),
2048: CompactPkePublicParams.safe_deserialize(crs2048, 400_000_000),
},
};
} else {
Expand Down

0 comments on commit 8768499

Please sign in to comment.