Thiru Vignarajah, a former deputy state attorney general, said his campaign had pulled the information from public sources as part of its research into the city’s rising water charges. After the ransomware struck and his team heard from water customers who said the city couldn’t provide them the amounts of bills from past months, Vignarajah realized the data could be put to another use.