Narrated An-Nu'man bin Bashir:
I heard Allah's Messenger (sallallaahu alayhi wa sallam) saying, 'Both legal and illegal things are evident but in between them there are doubtful (suspicious) things and most of the people have no knowledge about them. So whoever saves himself from these suspicious things saves his religion and his honor.
And whoever indulges in these suspicious things is like a shepherd who grazes (his animals) near the Hima (private pasture) of someone else and at any moment he is liable to get in it.
(O people!) Beware! Every king has a Hima and the Hima of Allah on the earth is His illegal (forbidden) things. Beware! There is a piece of flesh in the body if it becomes good (reformed) the whole body becomes good but if it gets spoilt the whole body gets spoilt and that is the heart.
[Sahih al-Bukhaari – The Book of Imaan – Superiority of the one who gives up doubtful things for the sake of his religion – Hadith No. 52]
Doubtful things are those for which you have evidence from one perspective that they may be permissible and evidence from another perspective that they may be impermissible. The scholar cannot say with complete confidence that they are impermissible and leaving such things constitutes wara' [godfearingness].
The scholars have differed in regards to the meaning of the doubtful things mentioned in this Hadith.
A group of scholars is of the opinion that these doubtful things are impermissible [haraam]. They have drawn evidence for their position from the following words of the Hadith:
So whoever saves himself from these suspicious things saves his religion and his honor
They say: Whoever does not save his religion and his honor has occurred in the haraam.
The other group of scholars is of the opinion that the doubtful things mentioned in this Hadith are permissible based on the following words of the Prophet (sallallaahu alayhi wa sallam):
like a shepherd who grazes (his animals) near the Hima (private pasture) of someone else
They say that what is around the Hima [private pasture] is not the private pasture itself and that is evidence that that is halaal [permissible] and giving it up is godfearingness [wara’]. And al-wara’ according to the Madhab if Ibn Umar, and those who agree with his Madhab, is abandoning a portion from the halaal [permissible] out of fear of falling into that which is impermissible.
The third group of scholars is of the opinion that one should not label the doubtful matters as halaal [permissible] or impermissible [haraam] because the Prophet (sallallaahu alayhi wa sallam) said:
Both legal and illegal things are evident
And since he did not include the doubtful matters into the impermissible or permissible, we should not do so either.
Regardless of the explanation of the meaning of doubtful matters, one is to leave them for the sake of protecting ones Religion and honor.
Sharh of Sahih al-Bukhaari by Ibn Battaal Volume 6 Page 193