No consular officer, nor any person under any consular officer shall make any charge or receive, directly or indirectly, any compensation, by way of commission or otherwise, for receiving or disbursing the wages or extra wages to which any seaman or mariner is entitled who is discharged in any foreign country, or for any money advanced to any such seaman or mariner who seeks relief from any consulate; nor shall any consular officer, or any person under any consular officer, be interested, directly or indirectly, in any profit derived from clothing, boarding or otherwise supplying or sending home any such seaman or mariner. Such prohibition as to profit, however, shall not be construed to relieve or prevent any such officer who is the owner of or otherwise interested in any vessel of the United States from transporting in such vessel any such seaman or mariner, or from receiving or being interested in such reasonable allowance as may be made for such transportation by law.