There is no fixed time period to repay back loans. As long as the user's position is safe (Health > 1) , borrowing can be done for an undefined period. However, as time passes, the accrued interest will grow making the user's Health decrease which might result in deposited assets becoming more likely to be liquidated.