It is a question that everyone needs to answer, “How is someone right before God?”
Job attempts to answer that question.
“Then Job answered and said:
Truly I know that it is so: But how can a man be in the right before God?
If one wished to contend with him, one could not answer him once in a thousand times.
He is wise in heart and mighty in strength
—who has hardened himself against him, and succeeded?—
he who removes mountains, and they know it not, when he overturns them in his anger,
who shakes the earth out of its place, and its pillars tremble;
who commands the sun, and it does not rise; who seals up the stars;
who alone stretched out the heavens and trampled the waves of the sea;
who made the Bear and Orion, the Pleiades and the chambers of the south;
who does great things beyond searching out, and marvelous things beyond number.
Behold, he passes by me, and I see him not; he moves on, but I do not perceive him.
Behold, he snatches away; who can turn him back? Who will say to him, ‘What are you doing?’ (Job 9:1-12 ESV)
It is Jesus who makes us right before God. John reminds us of this hope.
“I am writing to you, little children, because your sins are forgiven for his name’s sake.
I am writing to you, fathers, because you know him who is from the beginning.
I am writing to you, young men, because you have overcome the evil one.
I write to you, children, because you know the Father.
I write to you, fathers, because you know Him who is from the beginning.
I write to you, young men, because you are strong, and the word of God abides in you,
and you have overcome the evil one.” (1 John 2:12-14 ESV)
Praying a prayer of assurance of our salvation:
“And now little children (or adults), abide in Him, so that when He appears we may have confidence and not shrink from Him in shame at His coming. If you know that He is righteous, you may be sure that everyone who practices righteousness has been born of Him.” (1 John 2:28-29 ESV)