Shape reconstruction of defects in an elastic solid