RDSP- Investment within the belly

RDSP withdrawal question

I understand the penalty of withdrawing from an RDSP before the timeframe that is allowed due to the idea of it being meant for retirement. The 10 year rule, without getting into the specifics of making personal contributions and enhanced matching.

For low-income individuals or families who cannot make contributions, the government provides the Canada Disability Savings Bond (CDSB), contributing up to $1,000 annually without requiring personal deposits.

An RDSP account that has no personal contributions or enhanced matching used to invest in stocks, the gains can be withdrawn before the 10 year rule and the only penalty would be you need to pay back up to what the government contributed. In this case a person wouldn’t have to pay back $3 to every $1 withdrawn because there were no enhanced matching or personal contributions.

For example if the total CDSB was $20,000 and the investment gains from within the RDSP belly was $20,000 totalling $40,000, a person then would have to pay back the CDSB portion which was $20,000. You keep the gains of $20,000 if you withdraw early.

Does anyone know if I’m on the right track? There is very little information based on these specifics and when I ask this question most bankers will redirect the question.