This is Psalm 14 with some minor revisions. David wrote both of the Psalms.
Mahalath could mean disease. This is indeed a song for the man’s disease: the mortal sin of rejecting God.
David wrote Ps 14 at his early age, now advance in age, he found no difference in men. Men still reject God.
The major change is the use of Elohim “God” instead of Jehovah (the God of covenant).
The major difference is verse 5, in which the psalmist celebrates a military victory over an enemy.
Possibly revised by the psalmist to fit a new occasion, perhaps the defeat of the Assyrian army in the days of King Hezekiah.
v1-3 [there is no one that does good, not even one] was quoted by Paul in Romas 3:10.
The psalmist called the the atheist “fool”. (v1)
Atheists believe there is no God. They believe that they are living a moral life based on their own standards. But the bible says “There is no one who does good, not even one.” (v3)
Verse 5: “For God scattered the bones of him who encamped against you”. A body to remain unburied was a great disgrace in the ancient Near East, even an executed criminal was supposed to have a decent burial. The Lord despised the arrogance of the Assyrians and put them to open shame.