Who holds intellectual property rights on a thesis?
Your institution almost certainly has a policy on this, and an office dedicated to administering it.  You should consult them.  If you really think this is serious, you should also consult an intellectual property attorney rather than relying on the babblings of some goofball from the Internet (e.g. me).

In the US, employees of a university are commonly required to sign an agreement that the university has an interest in any patent or other profitable invention that they develop in the course of their work.  The agreement usually specifies that the royalties and other profits are to be split between the university and the inventor.

I have not heard of this being required of students, and if you had signed one, you would presumably know.  However, if your advisor had a significant part in the project, he or she may have some rights in it as a matter of law (and the university in turn would get a share of your advisor's, per their agreement).

Note that it may be relevant where the funding for the project came from, and what if any financial support you received from the university.