Some random thoughts on Socrates and the question of knowledge in the Charmides.
In the Charmides Socrates begins by trying to discover what temperance is by questioning a young man, Charmides, who is said to possess this character trait. Socrates assumes that if Charmides possesses it he must know what it is. (We will not be considering whether or not this assumption is true.) The discussion leads to a definition of Temperance borrowed from another. The definition given is: "minding one's own business (161b - all quotes from the Charmides can be found in "Plato: Complete Works, edited by John M. Cooper.)." Charmides could not say what was meant by this definition, so Critias, Charmides guardian, is called upon to explain and defend this definition. The questioning of Socrates leads Critias to change, ever so slightly his definition to, "the doing of good things (163e)," and the temperate man as, "the man who does what he ought (164b)." Temperance, at this point is a question of proper action. However, upon further questioning, Critias again changes his definition to say that Temperance is "to know oneself (164d - 165a)."
The rest of the dialogue will concentrate on this final definition to see if this is even possible. Socrates notes that if Temperance is knowledge (as defined as knowledge of oneself), then it is a science. In modern terminology science is often seen as having to do with physics, chemistry, biology, and other such domains of research, but a more accurate definition of the term would be to say that a science is a body of knowledge. (We might be able to say more, but for our purposes it is not necessary.)
The interesting point of the dialogue, for modern epistemology (which is the study of knowledge as knowledge), is when Socrates asks if such a science is possible. Socrates points out that Science, as a body of knowledge, is intentional, meaning, it is "of something." (see: 166a) Socrates then asks Critias about the object of this science; to which Critias responds, "this is the only science which is both of other sciences and of itself (166c-e)." The immediate question is: is it possible to have a science of science? Which is essentially what modern epistemology claims to be: a science which studies science. (I should think so, however, it seems that in order for it to exist, it must study its object, not declare, a priori, what it's object will look like.)
The problem that Socrates brings up is that this science, all while studying the other sciences, as sciences, must at the same time be over itself, studying itself. In Socrates own words, "But we are saying, it seems, that there is a science of this sort, which is a science of no branch of learning but is a science of itself and the other sciences (168a)." Socrates leaves us sceptical about the possibility of a science of science (a knowledge of knowledge), however, his very scepticism points the way to the response, that is, he notes, a number of times, that a science is, by definition, "of" something. He also notes that if there is a science of science, then it will be not only applicable to all sciences, but also to itself. In other words, we have an object for the science of sciences. The question is this, does this mean, that we are able to establish certain criteria, applicable to all bodies of knowledge, by which we can be certain that the subject in question is knowledge? This seems to be the point of section 171a-e. Each science has a different object, and, as such, the science of science cannot establish a criteria which will determine whether the doctor has knowledge of medicine - it is the science of medicine, with it's proper object, which determines what it means to have knowledge of medicine. In other words, each science is defined by it's proper object - knowledge is "of" an object, and the criteria for each branch of knowledge is determined by that branch.