parsing doc, improve access control