This image is from NOAA's GOES-15 Solar X-ray Imager taken on July 9th 2012 . The majority of the X-rays coming from the sun are produced in the corona. It's extremely high temperature, combined with strong magnetic field lines can produce flares or high energy X-rays. This event is extremely dramatic and shows a huge solar x-ray flare. We have solar wind physics combining with high energy magnetic/plasma physics to create these x-ray flares. We don't yet know the exact physics behind the extreme temperature of the corona and is a very big question in solar physicists' minds.