add some crypto function