decryptMetadata002 method
Implementation
Future<String> decryptMetadata002(String m, String key) async {
if (!m.startsWith('002')) throw Exception('Invalid version');
final iv = m.substring(3, 15);
final dk = pbkdf2(utf8.encode(key), utf8.encode(key), 1, 32);
final c = GCMBlockCipher(AESEngine())
..init(
false,
AEADParameters(KeyParameter(dk), 128,
Uint8List.fromList(utf8.encode(iv)), Uint8List(0)));
return utf8.decode(c.process(base64.decode(m.substring(15))));
}