Extract secname for exception.