I have heard that on one occasion the Blessed One was staying near Savatthi in the Eastern Monastery, the palace of Migara's mother. And on that occasion — the uposatha of the fifteenth, the night of a very full moon — he was sitting out in the open with the community of monks. Then, having surveyed the silent community of monks, he addressed them: "Monks, could a person of no integrity know of a person of no integrity: 'This is a person of no integrity'?"

"No, lord."

"Good, monks. It's impossible, there's no way, that a person of no integrity would know of a person of no integrity: 'This is a person of no integrity.'

"Could a person of no integrity know of a person of integrity: 'This is a person of integrity'?"

"No, lord."

"Good, monks. It's impossible, there's no way, that a person of no integrity would know of a person of integrity: 'This is a person of integrity.'

"A person of no integrity is endowed with qualities of no integrity; he is a person of no integrity in his friendship, in the way he wills, the way he gives advice, the way he speaks, the way he acts, the views he holds, & the way he gives a gift.

"And how is a person of no integrity endowed with qualities of no integrity? There is the case where a person of no integrity is lacking in conviction, lacking in conscience, lacking in concern [for the results of unskillful actions]; he is unlearned, lazy, of muddled mindfulness, & poor discernment. This is how a person of no integrity is endowed with qualities of no integrity."

"And how is a person of no integrity a person of no integrity in his friendship? There is the case where a person of no integrity has, as his friends & companions, those brahmans & contemplatives who are lacking in conviction, lacking in conscience, lacking in concern, unlearned, lazy, of muddled mindfulness, & poor discernment. This is how a person of no integrity is a person of no integrity in his friendship.

"And how is a person of no integrity a person of no integrity in the way he wills? There is the case where a person of no integrity wills for his own affliction, or for the affliction of others, or for the affliction of both. This is how a person of no integrity is a person of no integrity in the way he wills.

"And how is a person of no integrity a person of no integrity in the way he gives advice? There is the case where a person of no integrity gives advice for his own affliction, or for the affliction of others, or for the affliction of both. This is how a person of no integrity is a person of no integrity in the way he gives advice.

"And how is a person of no integrity a person of no integrity in the way he speaks? There is the case where a person of no integrity is one who tells lies, engages in divisive tale-bearing, engages in harsh speech, engages in idle chatter. This is how a person of no integrity is a person of no integrity in the way he speaks.

"And how is a person of no integrity a person of no integrity in the way he acts? There is the case where a person of no integrity is one who takes life, steals, engages in illicit sex. This is how a person of no integrity is a person of no integrity in the way he acts.

"And how is a person of no integrity a person of no integrity in the views he holds? There is the case where a person of no integrity is one who holds a view like this: 'There is nothing given, nothing offered, nothing sacrificed. There is no fruit or result of good or bad actions. There is no this world, no next world, no mother, no father, no spontaneously reborn beings; no brahmans or contemplatives who, faring rightly & practicing rightly, proclaim this world & the next after having directly known & realized it for themselves.' This is how a person of no integrity is a person of no integrity in the views he holds.

"And how is a person of no integrity a person of no integrity in the way he gives a gift? There is the case where a person of no integrity gives a gift inattentively, not with his own hand, disrespectfully, as if throwing it away, with the view that nothing will come of it. This is how a person of no integrity is a person of no integrity in the way he gives a gift.

"This person of no integrity — thus endowed with qualities of no integrity; a person of no integrity in his friendship, in the way he wills, the way he gives advice, the way he speaks, the way he acts, the views he holds, & the way he gives a gift — on the break-up of the body, after death, reappears in the destination of people of no integrity. And what is the destination of people of no integrity? Hell or the animal womb.

"Now, monks, could a person of integrity know of a person of no integrity: 'This is a person of no integrity'?"

"Yes, lord."

"Good, monks. It is possible that a person of integrity would know of a person of no integrity: 'This is a person of no integrity.'

"Could a person of integrity know of a person of integrity: 'This is a person of integrity'?"

"Yes, lord."

"Good, monks. It is possible that a person of integrity would know of a person of integrity: 'This is a person of integrity.'

"A person of integrity is endowed with qualities of integrity; he is a person of integrity in his friendship, in the way he wills, the way he gives advice, the way he speaks, the way he acts, the views he holds, & the way he gives a gift.

"And how is a person of integrity endowed with qualities of integrity? There is the case where a person of integrity is endowed with conviction, conscience, concern; he is learned, with aroused persistence, unmuddled mindfulness, & good discernment. This is how a person of integrity is endowed with qualities of integrity."

"And how is a person of integrity a person of integrity in his friendship? There is the case where a person of integrity has, as his friends & companions, those brahmans & contemplatives who are endowed with conviction, conscience, concern; who are learned, with aroused persistence, unmuddled mindfulness, & good discernment. This is how a person of integrity is a person of integrity in his friendship.

"And how is a person of integrity a person of integrity in the way he wills? There is the case where a person of integrity wills neither for his own affliction, nor for the affliction of others, nor for the affliction of both. This is how a person of integrity is a person of integrity in the way he wills.

"And how is a person of integrity a person of integrity in the way he gives advice? There is the case where a person of integrity gives advice neither for his own affliction, nor for the affliction of others, nor for the affliction of both. This is how a person of integrity is a person of integrity in the way he gives advice.

"And how is a person of integrity a person of integrity in the way he speaks? There is the case where a person of integrity is one who refrains from lies, refrains from divisive tale-bearing, refrains from harsh speech, refrains from idle chatter. This is how a person of integrity is a person of integrity in the way he speaks.

"And how is a person of integrity a person of integrity in the way he acts? There is the case where a person of integrity is one who refrains from taking life, refrains from stealing, refrains from illicit sex. This is how a person of integrity is a person of integrity in the way he acts.

"And how is a person of integrity a person of integrity in the views he holds? There is the case where a person of integrity is one who holds a view like this: 'There is what is given, what is offered, what is sacrificed. There are fruits & results of good & bad actions. There is this world & the next world. There is mother & father. There are spontaneously reborn beings; there are brahmans & contemplatives who, faring rightly & practicing rightly, proclaim this world & the next after having directly known & realized it for themselves.' This is how a person of integrity is a person of integrity in the views he holds.

"And how is a person of integrity a person of integrity in the way he gives a gift? There is the case where a person of integrity gives a gift attentively, with his own hand, respectfully, not as if throwing it away, with the view that something will come of it. This is how a person of integrity is a person of integrity in the way he gives a gift.

"This person of integrity — thus endowed with qualities of integrity; a person of integrity in his friendship, in the way he wills, the way he gives advice, the way he speaks, the way he acts, the views he holds, & the way he gives a gift — on the break-up of the body, after death, reappears in the destination of people of integrity. And what is the destination of people of integrity? Greatness among devas or among human beings."

That is what the Blessed One said. Gratified, the monks delighted in the Blessed One's words.

I think "integrity" is used in the sense of "virtuous". Bhikkhu Bodhi's translation is "true":

“Bhikkhus, would an untrue man[*] know of an untrue man: ‘This person is an untrue man’?”—“No, venerable sir.”—“Good, bhikkhus. It is impossible, it cannot be, that an untrue man should know of an untrue man: ‘This person is an untrue man.’ But would an untrue man know of a true man: ‘This person is a true man’?”—“No, venerable sir.”—“Good, bhikkhus. It is impossible, it cannot be, that an untrue man should know of a true man: ‘This person is a true man.’