The Psalms are filled with references to God being our Rock and refuge. king David was not the most innocent person in the Bible: he committed adultery, was certainly guilty of envy and lust, and more or less guilty of murder. David certainly understood one thing: God was his refuge and the only path to salvation. He begged for forgiveness numerous times, realizing his sins, begging for atonement, and having faith in The LORD, his Rock and refuge.
And we pray:
Hallowed and holy Lord, I must release the darkness from my heart. I beg that You forgive me of the sins that I have committed, and thank You for always being there for me: my Rock, Refuge, and Redeemer. Give me the faith to know that You will never forsake me. You are my helper, LORD. I will not be afraid. With this knowledge, what can man do to me? I long for the day I join You and Your son in Heaven, almighty God. Amen.