0

Where can I find out who tries to access sites to which they don't have access to?

Is there a list of users that got "access denied" errors?

  • I guess you saw this answer? It is not for 2013 though, but auditing in general would be a good place to start. Another alternative is to just look at the IIS logs (or ULS, but IIS should be enough) – eirikb Apr 25 '14 at 6:55
2

The User Information List can be accessed (Only if you’re admin) via the browser by navigating to /_catalogs/users/simple.aspx from your site.

Maybe this can help you to see the users who visited your site. Then, you can click on the user and check his permissions, maybe...

http://zimmergren.net/technical/sharepoints-hidden-user-list-user-information-list

  • This list helps me but it would be easier to have a list or log file with only the users that got an access denied error. – jlai79 Apr 25 '14 at 6:40
  • Maybe there is a feature which does this like security auditing? Just guessing. – variable Apr 25 '14 at 6:46
1

You Can yourself log it using jquery. Create a custom list with 2 columns Source(for url the user was trying to visit) and UserName (the user herself) then on access denied page using JSOM, Add item to custom list with Url and Current user.

var siteUrl = 'http://siteurl';


function createListItem() {

    var clientContext = new SP.ClientContext(siteUrl);

    var oList = clientContext.get_web().get_lists().getByTitle('LogList');


    this.oListItem = oList.addItem(itemCreateInfo);

    oListItem.set_item('Url', 'Url from Jquery');
    oListItem.set_item('UserName', website.get_currentUser());
    oListItem.update();

    clientContext.load(oListItem);

    clientContext.executeQueryAsync(Function.createDelegate(this, this.onQuerySucceeded), Function.createDelegate(this, this.onQueryFailed));
}

function onQuerySucceeded() {

    alert('Item created: ' + oListItem.get_id());
}

function onQueryFailed(sender, args) {

    alert('Request failed. ' + args.get_message() + '\n' + args.get_stackTrace());
}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.