It is best to consult a specialist tax agent/consultant
But in general, my understanding is:
(1) International tax is covered by "double tax agreements" between nations
(2) Countries that have a tax treaty with Australia are:
Argentina Austria Belgium Canada China Czech Republic Denmark Fiji Finland France Germany Hungary India Indonesia Ireland Italy Japan Kiribati Malaysia Malta Mexico Netherlands New Zealand Norway Papua New Guinea Philippines Poland Romania Russia Singapore Slovakia South Africa South Korea Spain Sri Lanka Sweden Switzerland Taipei Thailand United Kingdom United States Vietnam
(3) If you earn Australian income using an Australian broker that provides mere brokerage services (rather than makes decisions on your behalf) and if there is a double tax agreement between your country and Australia then you declare your ASX income as foreign income in your domestic tax return and are not required to lodge an Australian tax return.
(4) If you use a domestic (non-Australian) broker to trade on the ASX then your ASX income is not "foreign income" & just ordinary domestic income.
(5) But, if where you live is not covered by a double tax agreement then you will probably have to pay tax in Australia and lodge and Australian tax return.
(6) if your Australian broker has the authority to buy & sell on your behalf, independent of your instruction, then that appears to be Australian income and must be taxed in Australia because the authorised broker is consider to be a "permanent business establishment" in connection with you.
(see: CASE 23/93 93 ATC 288 at http://law.ato.gov.au/atolaw/view.htm?dbwidetocone=05%3ALRP%3AAdministrative%20Appeals%20Tribunal%3A1993%3AAAT%20Case%208775%20-%20(11%20June%201993)%3A%23001%23Judgment%20by%20BJ%20McMahon%20(Deputy%20President)%26c%3B)
Impact of Australia's tax treaties Where a non resident is a resident of a country with which Australia has concluded a tax treaty, then Australia's taxing rights with respect to Australian sourced income may be limited to where the non resident carries on business in Australia through a permanent establishment.
Broadly, a permanent establishment (PE) will exist where the non resident has a fixed place of business through which the enterprise carries on business. Any profits attributable to that PE will then be taxable in Australia. The definition of a PE may differ under the relevant double tax agreements and generally the Treaty definition overrides domestic law to the extent of any inconsistency.