cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
What’s new: end-to-end encryption, Replay and Dash updates. Find out more about these updates, new features and more here.

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Compute content_hash of local folder

Compute content_hash of local folder

PeterG-TDA
New member | Level 2
Go to solution

Hi, I've implemented content hashing for local files using the instructions found here dropbox content-hash page  - very helpful article!

 

Next I'd like to implement content hashing for folders locally. So I can then compare to a remove Dropbox folder's content_hash (and download or not download a folder accordingly).

 

What is the best way to generate a content_hash for a folder locally?

  • Hash individual files (in the folder) one at a time and then hash the concatenated SHA-256 strings? If so, what would be the order of the files to hash sequentially?
  • Can the folder be hashed (rather than each file)? This would be far more efficient!
  • Can detailed instructions please be provided?

 

Thank you very much.
Peter

1 Accepted Solution

Accepted Solutions

Greg-DB
Dropbox Staff
Go to solution

Dropbox doesn't offer a 'content_hash' or equivalent for entire folders, only files, but I'll pass this along as a feature request. I can't promise if or when that might be implemented though.

 

If you want to verify an entire folder, you'd need to check each individual file in the folder you're interested in verifying.

View solution in original post

2 Replies 2

Greg-DB
Dropbox Staff
Go to solution

Dropbox doesn't offer a 'content_hash' or equivalent for entire folders, only files, but I'll pass this along as a feature request. I can't promise if or when that might be implemented though.

 

If you want to verify an entire folder, you'd need to check each individual file in the folder you're interested in verifying.

PeterG-TDA
New member | Level 2
Go to solution

Thanks for letting me know Greg.

 

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    PeterG-TDA New member | Level 2
  • User avatar
    Greg-DB Dropbox Staff
What do Dropbox user levels mean?