download data should be cached
implement public key checking
refine caching methods