There's no easy way to tell how it's attached. Just grabbing it with a wrench might break things off inside the wall. That appears to be a frost-free silcock, and if you can identify the brand, they usually have rebuild kits available. A frost free silcock generally doesn't work if there's a hose attached, and it's possible the valve has split inside if it was there when it got below freezing for awhile. You may need to tear into the wall or ceiling to get a proper view in order to replace it.