There are several (if not many) projects doing resource discovery. One that I like has been implemented at uiuc.edu by the srg group. The protocol badsrv is using is very naive and will be replaced. The code used now is just enough to get everything else working.