... $uin = (getpwuid((stat $filename)[4]))[0]; ...