Got enc/dec working again