changed open and added return values in read from proxy