I should probably finally post what I did awhile ago based on this very question!
At my Github repository, I have compiled test vectors for
- PBKDF2-HMAC-SHA-512
- PBKDF2-HMAC-SHA-384
- PBKDF2-HMAC-SHA-256
- PBKDF2-HMAC-SHA-224
- PBKDF2-HMAC-SHA-1
And for the crazy or those with ancient systems without even SHA-1 support:
- PBKDF2-HMAC-MD5
Tests started with RFC6070 and those in the answer by @ChristianAichinger above for PBKDF2-HMAC-SHA-256, and added a few dozen more to implement more stringent tests, such as boundary conditions around certain sizes of password and salt (15/16/17 bytes, 63/64/65 bytes, 127/128/129 bytes, 1025 bytes etc.), large iteration counts, large output size counts, and so on and so forth.
I then gathered up many instances of PBKDF2, and validated these test vectors against every major implementation I was able to find (all also included in the above repository, sometimes including Windows MinGW executables and generally including Linux compilation instructions), including
- Python (hashlib)
- Python (warner's custom code)
- C (OpenSSL)
- C (PolarSSL)
- C++ (Cryptopp)
- .NET 4.5 (@Jither's DeriveBytes)
- SQL Server (custom code, PBKDF2-HMAC-SHA-1 and PBKDF2-HMAC-SHA-512 only right now)
Given that I'm seeing identical results across 7 implementations using 5 different languages using multiple major cryptographic libraries, I'm extremely confident that not only are the test vectors provided accurate, but that the implementations provided can be used as a set to validate any other test vector set desired. If they all agree, then it's correct.