If the horse appears sore and is avoiding the rear of it's hoof, then there's a good chance it's because of the thrush. Thrush can be painful to horses and they'll walk on their toes to avoid the pain.
First thing to do would be to treat the thrush with something. There's lots of different things you can use. Some good, some not so good.
I've used apple cider vinegar before, and I've also used something which has been termed, "Petes Goo". Which is neosporin, "I use the cheaper generic version", and an antifungal cream that has 1% clortrimazole. Mix that up 50/50 and apply it into the deep thrushy cracks.
The next thing I would recommend is lots of stimulation to the rear of the hoof. It's kind of one of those scenarios where the horse is avoiding the rear of it's hoof cus it's painful. But at the same time if it gets stimulation back there it will help to, "outrun", the thrush. Boots and pads can be helpful for this. You can vary the degree of padding so that the horse is getting stimulation to it's frog with heel first landings. Then as the thrush begins to go away you can hang the boots and pads up.
I'm not saying that boots and pads are a necessity. But I've used em before to help stimulate the hoof and "outrun" thrush.
Truth passes through three stages. First it is ridiculed. Second it is violently opposed. Third it is accepted as self evident.