new class domain + decrypt function(still buggy)