Japanese right triangle

There is a right triangle where: the sum of the upright multiplied by itself twice and the hypotenuse multiplied by itself is 700 units; and, the sum of the base multiplied by itself twice and the hypotenuse multiplied by itself is 900 units.  What is the length of the sides of this triangle? (Takebe Katahuo, Japan, c. 1700)