Background...
My wife and I have been married for nearly 6 years, we have 3 kids, I and the kids are US Citizens, she is not (she has a green card). We were married overseas. However I was previously married, in California with a "Confidential Marriage" in the mid-90s, to a foreign spouse from another country. We were divorced overseas, not the country where I married my current wife. We now reside in California and will be looking to convert her Green Card to a Citizenship. I have since found out that my previous marriage was not yet given its divorce certificate at the time we married which means that my marriage may not be considered legal, I have it now though. And we are likely looking to get re-married to ensure the marriage’s validity.
I do not remember if, in her migration and green card application, there were any questions relating to me either having been married before or not. If there were I would have either said no or not answered the question. I do not know if these questions will come up in the naturalization process either. I do not wish to misrepresent anything.
So I am wondering if I bring up the divorce will that throw a spanner in the works, in terms of her getting citizenship or her being able to stay here (although we may not currently be legally married). I would like to say I was previously married and divorced if I am asked, but want to ensure that we are legally married.
BTW, my wife came here on a tourist visa then we decided to move here. She was brought in as my spouse, I sponsored her but I had to be sponsored by a family member, because I was unemployed until after we settled.
Is my wife legal in this country, now?
In this situation are there any negative ramifications for now saying I was divorced, if I had not mentioned the first marriage before? Will it help to re-marry here, in California? Where should we get married again? Should we re-marry or have some kind of civil ceremony? We do not want to mess up the naturalization process. Also what if we re-marry after the naturalization?
Doesn't Immigration or the Dept of Homeland Security check previous marriages and the like out, when applying for a Green Card or Naturalization? Shouldn't this have already been noted somewhere or in my wife's file or perhaps in running a background check on me? Note though that my first wife and I never filed any tax returns or anything together in the USA, we were only married less than a year here.
What should we do? Will we get into trouble?
Any advice that you may have is greatly appreciated.
Thanking you.

