This question is hypothetical.
If I am an independent contractor doing work for a company in my home country while located abroad (working via internet can be very normal without appearing at an office).
In such case, will I need to apply for a tourist visa or for a working visa? Does the answer depend on the visiting country or my home country? Are there any types of legal issues I might need to worry about?