I visited an optometrist today for my eye appointment. He was a pretty nice guy and went though everything pretty quick (I have 20/20 vision). I remembered this topic and asked him if rubbing my eyes would damage them - he said it wouldn't. I rub my eyes all the time (corner, under, eyelids, whatever), so there ya go! But I am sure it is not good from a cosmetic viewpoint as the area where I rub my eyes the most (under the eye) looks slightly more red / tender.
I didn't go any further with discussing this topic with him. A lot of it is obvious - things like: if there is something rough in your eye and you rub it it would scratch your cornea and cause damage.
If I have time I will do some research on this and post what I find here.
EDIT: If the corner of your eyes feel sore and gooey and you keep rubbing them all the time (and it's been like this for a while), then you may want to see a doctor / optometrist (could be an infection, or something stuck in your eye...). But you said you are rubbing your eyes at the minute, mainly due to sleep problems... If you're rubbing your eyes the most at night due to sleep problems, then you should remedy your sleep problems.