Depending on where you live and the local laws, these are questions that are not considered to be legal interview questions but not actually be illegal to ask. An example of an unethical question would be one that asks you to divulge secret or confidential information about your current employer.
This might be a legal interview question but it's one that simply shouldn't be asked.
Another example of an unethical question would be one that asks you to do something that would benefit the company you are interviewing with and in exchange for doing it, would result in you getting the job. I've actually heard of companies who use a recruiter to find staff but then tell the job candidate that they will hire them under the table by cutting the recruiter out of the deal in order to not have to pay the recruiter!
Would you want to work for a company that treats people like this?
Another example of an unethical question would be one that isn't actually unethical to ask but describes an unethical situation that you might face in your career and asks how you'd respond to the situation.
For example, I've heard the following question asked in an interview and the goal of asking the question was to gauge how the interviewee dealt with a hypothetical unethical dilemma that was posed to them:
Imagine that you have a chance to increase sales in your company by a significant amount of money by securing a very valuable contract that is worth $2 million. In order to gain this $2 million contract through, the person you are negotiating with has suggested that an under the table (ie. illegal or unethical) payment needs to be paid.
How would you respond?
In other words, would you accept the terms and make an under the table payment or would you walk away and refuse to make the payment but lose out on the $2 million contract in the process, perhaps to a major competitor?
A third way to handle the problem is probably the most effective and correct way to answer the question: keep negotiating until everything is above the table!
In other words, negotiate until everything is above-board and legal.
True, this would be an ideal result but remember this is just a hypothetical question and the interviewer would most likely be assessing your credibility and ethics to see how you deal with unscrupulous people.
The last thing a company wants to do is hire someone who does things "the wrong way!"