You should not stare at the sun yourself. As an astronomer who does a lot of solar outreach, I have to give the safety lecture every time I bring students to the telescope because even though I'm about to let them look the sun using instruments specifically designed to be safe for the purpose... I don't want them getting the idea that it's ok to stare at the sun without the benefit of the equipment to protect their eyes.
The human eye has no pain receptors in it. So as you're killing the cells in the back of your eye, you won't feel a thing. Also... the effect isn't instant. After the damage is done, it can take between 24-48 hours for the cells to die. So you stare at the sun, felt no pain, think you got away with it and this "no staring at the sun" thing is all overblown... and you wake up 1 to 2 days later and realize you can't see (or your vision is severely degraded.)
The amount of time it takes to damage your eye depends on your age and how small your pupils can constrict. Young children might get away with a little over a minute. As we age our pupils won't constrict as much (which is why driving at night is more annoying than when we were young) and just 40 seconds may be enough to result in permanent damage. And since everyone is different... some people will get damage sooner than that.
So with that safety lecture out of the way...
When the sun is very low in the sky (sunrise & sunset) it's much safer. Point the camera away from the sun to take a meter reading because no matter what you use an exposure the sun will still be overexposed (so you're not really trying to get the right exposure for the sun... you're trying to get the right exposure for "everything else" in the image besides the sun.)
When we had our partial solar eclipse a few months back, I used a Thousand Oaks brand solar filter on my 300mm lens (this is a filter intended to go on the end of telescopes but I happen to own a size that nicely caps over the front of my 300mm lens). These filters allows about 1 photon out of every 100,000 to penetrate and render the sun at a safe level.
If you're interested in a source for safe solar filters, here's one:
Solar Filters
(incidentally the filters go over the end of a telescope (or in my case I put it over a lens) like a "cap". You measure the outer diameter of the lens and make sure you order a size where the inner diameter is big enough to fit over (the inside is lined with felt to provide a snug fit and avoid scratching.)
BTW, that solar filter works out to about an ND 5.0 (16.66 stops of light reduction). But you can't use just "any" ND filter... it has to be formulated for the sun. The sun pumps out nearly as much damaging light in the IR spectrum as it does in the visible spectrum. Many modern filters use polymers that are just designed to block visible light and don't block the IR at all (there are cases of people ending up with damaged vision who actually did use filters that rendered the sun dim... but didn't use proper "solar" filters so they had no IR protection and cooked their retinas anyway.)
Meanwhile back to the camera... if the sun is high, I would be cautious about pointing the camera at it very long. I have a buddy who set up his LX200 to look at the sun and he did this with another buddy. While he was getting his scope ready, he put the solar filter on the front of the telescope, but he left his finder attached (with front and back caps on). What he DID NOT notice... was his buddy was busy taking off the all the caps. When he pointed the scope at the sun, it was there merely a few seconds and they both smelled the scent of burning plastic... look up and notice that the sun had torched a hole through the back cap of his finder scope. Why? Because his buddy removed the FRONT cap from that same finder scope. The finder is scope is an 8x50 (50mm aperture... 8x power). That was enough to burn a hole clean through the back cap (and also snap the wires that create the cross-hairs).
8x power on an APS-C size DLSR would be 232mm. So if you've got, say... a 50-250mm zoom lens, then when you zoom in you have roughly the same amount of power as this finder scope would have. Thanks to your reflex mirror, that energy isn't trying to burn a hole through your shutter and destroy your sensor. Instead... it's trying to burn a hole through your focusing screen.
Here's an image that my partner and I shot while I was doing a solar outreach for a local college during the last partial solar eclipse. I set up my camera and filter and had him track and snap away... while I continued to man a "white light" solar scope and a "Hydrogen alpha" solar scope.
This image is shot through a 300mm lens with a "white light" solar filter attached. The filter is tuned to allow more reds than other colors hence the orange colored sun, but we call it "white light" because it does allow full-spectrum. This is to differentiate it from images taken in narrow-band... such as a Hydrogen alpha solar scope (which only allows the 656nm wavelength to pass through the filter and all other wavelengths are blocked.)