localhost auth: resolve localhost to [::1] if using ipv6

http://camlistore.org/issue/238

Change-Id: Icab7d87fe651365fb44db4c2874d4976fa631ad6
Merge "localhost auth: resolve localhost to [::1] if using ipv6"
auth: maybe fix IPv6 test on IPv6-less Linux

Change-Id: I438388420854014e862587960bc549fbcc8f3f2d