In case of an open source project, use web service
for assigning username
and password
to the user who is using project with there application. To implement this, you need to implement some SOAP base approach with axis-2
in java, if that LIB is build in java and simply call the methods with your business logic.
Last but not the least, try to create username and password for the user who download's this LIB so that you don't need to share your username and password with the jar of source files .