When I turn my phone on it now says custom...

Reflash the stock ROM - see [Samsung] How to flash Stock ROM via ODIN. Be prepared to die of boredom if you don't have something to do. Setting up the flash takes a couple of minutes - then it can be 10 minutes before the phone is flashed, restarted and ready to go. And you're just looking at what's as about as exciting as grass growing in the winter.

You'll lose all your downloaded apps and all your data (pictures, videos, music, etc.) because you can't get the phone to the point that you can back it up (unless you always kept it backed up).
 
I just recently had the same problem of my phone turning off and on over and over until I took out the battery. This was after weeks of my battery draining at a rate of 10% every 15 minutes. I thought my battery had gone bad so I bought a new one. However, I never had the Downloading message.

Then I noticed the Custom message with the open padlock. I have no idea how long that had been there because I don't watch my phone that closely when restarting. I had never rooted my phone and don't download many apps but assumed somehow my phone had been compromised. I've head of a lot of people losing key functionality when having this message but my only functional issue was the batter draining rapidly.

I saw another forum with the following advice and it worked to get rid of the message:

Turn your phone off
Hold HOME + LOCK + VOLUME UP until the phone vibrates indicating it is restarting
When the menu pops up, only take the Reboot option

The Custom message with the open padlock does not appear any longer but I don't know about the battery. I just did this minutes ago.
 
Hey Joe, I was reading your posts back from the end of 2014 thru Jan 2015 regarding the Custom Lock that was on your phone. I have the same issue plus the phone turns of and on constantly. I've replaced the battery twice. The phone gets incredibly hot. Mostly I can't even get it to turn back on. It's basically unusable. I bought it 5 months ago from Best Buy. Of course they think I downloaded something to make it Custom or what you guys call rooting. I never knew what rooting was until I came to this site. I don't want it to be rooted because I'd like the opportunity for Samsung to replace it. Sometimes I can get it up and running - so is there something I can download to fix this. Best Buy said to maybe download the original software by getting it from the internet. I have reset it to factory already or so I think I have. It's a Samsung S5. Wondering if you ever found a fix. Please help!!! Thanks.
 
Hey Joe, I was reading your posts back from the end of 2014 thru Jan 2015 regarding the Custom Lock that was on your phone. I have the same issue plus the phone turns of and on constantly. I've replaced the battery twice. The phone gets incredibly hot. Mostly I can't even get it to turn back on. It's basically unusable. I bought it 5 months ago from Best Buy. Of course they think I downloaded something to make it Custom or what you guys call rooting. I never knew what rooting was until I came to this site. I don't want it to be rooted because I'd like the opportunity for Samsung to replace it. Sometimes I can get it up and running - so is there something I can download to fix this. Best Buy said to maybe download the original software by getting it from the internet. I have reset it to factory already or so I think I have. It's a Samsung S5. Wondering if you ever found a fix. Please help!!! Thanks.

Hello awesome9. I know the issue you are having and I'm here to help at least In one segment. Now your gonna wanna get a pc for this cause you need to download the android operating system for your exact carrier and phone model you can do so by going to settings about phone and it should all be there. Then just go ahead and type in for example. Samsung Galaxy s5 att stock rom.. and that should pull what u need and I will link a guide at the bottom of this reply but it will be pretty much straight forward from there and it will reset everything so back up everything. And it will fix everything you had problems with also after your done flashing turn phone off and press and hold power,home,volume up then do a factory reset and clear cache. That should help.
How to Unbrick AT&T Galaxy S5 SM-G900A Soft-brick Fix & Restore to Stock Firmware Guide - GalaxyS5Update