Ukraine’s worst cyberattack in four years brought down the websites of scores of government agencies for hours. Authorities didn’t immediately identify the source of the hacks, which took place as tensions with Russia intensified over its troop buildup across the border.