What is this??

I have been having stomach issues for the passed week and I just found this when I used the restroom. It's hard and gross. Is it old blood? Sorry for the gross picture..