Hello !
I have read your post and issue seems with you are logged out while using safari .
To sort out the issue it is recommended not to use any anti virus , third party software , Firefox in the system as they create more issues .
Please click on go to go folder & type ~/Library , remove the contents ( you can use command + A ) to select all of the contents of caches , cookies , saved application state , safari ( except book marks ) , application support , logs , what is in launch agents ?
make sure internet plug -ins , input methods are empty .
In, your second screen shot , make sure the second option require admin password to access system wide preferences should be checked in , also the option log out after ... minutes of inactivity is optional , and you select this check box , if you are away from system and you choose 5 min ( just an example ) the system will automatically log out after 5 min .
Make sure , you have latest adobe flash player version installed on the system , click on updates in adobe flash player .
Open safari , safari preferences under security > check the box allow WEBGL , click on WEBGL settings choose as ask when visiting other websites .
Select the box allow plugins , click on plug - in settings select the box for adobe flash player & choose as on , in share point browser plugin select the box , and choose as on , when visiting other websites as on or ask .
Finally click on done .
Also in the mission control settings as in screen shot of yours settings are not done .
Please do the settings as :

Thanks !