The code base got just a few days of after-work hacking, so probably this will take a few more days to be ready.
Thanks for the hint.
SHA1(SHA1(SHA1(0|pass)|1)|2) and so forth.
This way there is no requirement for an additional library.
(The difference between this and PBKDF1 is that PBKDF1 requires using either MD2 or SHA1 as the hash function, and hasn't been updated to reflect the availability of SHA-256 and SHA-512.)
I guess that the xor approach used in PBKDF2 is useful since you want to compute T1, T2, T3 ..., Tc that are multiple output blocks all starting from the same input, so this gives more information to the attacker and the schema is designed to avoid showing some "state" that is possible to more easily analyze. Not sure, but the point is, I don't think PBKDF1 is unsafe either, and it is just chaining.
Your code is neat. I don't care what hash you use. I'm just saying.
SHA256(SHA256(... SHA256(password + salt)))
With perhaps five thousand iterations of SHA256, if you really don't want to depend on bcrypt. Or just use bcrypt; it's a good library, and removes the temptation to get creative with password hashing.
However, it should be noted that I'm thankful that the author decided to share this.
But actually... I can just run it easily in a server of mine just to show it to you. Let's try to install it... just a moment.
I'll leave it running for a few hours assuming it will not crash. It's very new code ;)