From the URL you’ve got take extract the image name (2177060015_258bcfaff9_m.jpg) and split it on the underscore. The first part is the photoID, the second part is the hash/salt and (if there) the third part the size (Full format: photoId_hash_size.jpg).