Probably not legal but difficult to say without lots more info. Maybe get a local electrician to cast his/her beady eye over it and give you some advice.