In 1544 the Tarnopol Castle was completed and repelled the first Tatar attacks. On 20 January 1548, Tarnopol was granted legal rights by the King of Poland Sigismund I the Old which allowed the town to hold three fairs annually, and the weekly trades on Mondays. Tarnopol received Magdeburg city rights two years later from Jan Tarnowski, regulating the duties of town residents. In 1548 the King of Poland also gave permission to create a pond near the Tarnopol suburb of Kutkovets. In 1549 the city managed to survive a Tatar siege by efforts of the Polish Duchess Eudokia Czartoryska (see House of Czartoryski). After the death of the Crown Hetman in 1561, Tarnopol became the property of his son Jan Krzysztof Tarnowski, who died childless in 1567. Starting in 1567 the city was owned by the daughter of Crown Hetman Zofia Tarnowska who was married to Konstanty Wasyl Ostrogski. In 1570 she died in childbirth, and Tarnopol was passed to the Ostrogski family. In 1575 it was plundered by the Tatars. In 1623 the city passed to the Zamoyski family. In 1589 Tarnopol was visited by the Austrian diplomat who also mentioned the city's castle.