For the first question, read this:
http://www.askimam.org/fatwa/fatwa.p...47fd1373f18d7b
For the second one, yes, the Banu Qurayzah betrayed the Muslims and broke the treaty by allying themselves with the kuffar of Makkah. The punishment against them is not in accordance to Shari'ah (Shari'ah does not allow killing of prisoners who have surrendered until they are found guilty of punishments that require such punishment) but it was in accordance with Jewish law. Banu Qurayzah wanted a lenient punishment so they suggested to Rasoolallah (saw) to have Sa'ad bin Mu'az (ra), who was an Ansar and was seen as an ally by the Banu Qurayzah, to decide what the punishment would be. Sa'ad bin Mu'az (ra) gave the punishment according to the following passage from Deuteronomy 20:
10When thou comest nigh unto a city to fight against it, then proclaim peace unto it.
11And it shall be, if it make thee answer of peace, and open unto thee, then it shall be, that all the people that is found therein shall be tributaries unto thee, and they shall serve thee.
12And if it will make no peace with thee, but will make war against thee, then thou shalt besiege it:
13And when the LORD thy God hath delivered it into thine hands, thou shalt smite every male thereof with the edge of the sword:
14But the women, and the little ones, and the cattle, and all that is in the city, even all the spoil thereof, shalt thou take unto thyself; and thou shalt eat the spoil of thine enemies, which the LORD thy God hath given thee.
Bookmarks