Skip to content

Instantly share code, notes, and snippets.

View ProKashif's full-sized avatar
🏡
Working remotely

Kashif Ahmed ProKashif

🏡
Working remotely
View GitHub Profile
@ProKashif
ProKashif / gist:85dadae0e04bef64172eb3234128c802
Created July 21, 2020 14:24
How to integrate Easypaisa with react-native
Add 3 packages :
import AesJs from 'aes-js';
import { Buffer } from 'buffer';
import queryString, { stringify } from 'query-string';
// Generating bytes encryption in AES, ECB mode with easypaisa HashKey
const aes = new AesJs.ModeOfOperation.ecb(AesJs.utils.utf8.toBytes(APP_STRING.HASH_KEY));
function pkcs5Pad(text: string, blockSize: number): string {