If you forget password of app pool, it is very difficult to retrieve password. There is a simple command for this. Just go to you command prompt and type below command:
C:\Windows\System32\inetsrv\appcmd.exe list apppool -config
It will return a XML file.