Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

Disable Guests from using Fileupload

Im trying to figure out how to disable this addon when guests who doesnt have an account to log in can still use the Fileupload to upload files. I made a role for "Guest" and "Guests" and unchecked permissions Attachments Download and Attachments Upload but when I go back to it, it's still checked...It doesnt work. How can I fix this? Thanks

Comments

  • Options
    vrijvlindervrijvlinder Papillon-Sauvage MVP
    edited June 2013

    You need to make sure the users are not guests and lock the guest role down.Guests should not have any permissions. There is already or should be a default guest role. But you need to designate the roles you make if you make new ones.

    The file upload as well as the form should not appear to guests at all. I did not see the form when I went as a guest. It sent me to the sign in page.

    Check to make sure you have set roles correctly.

  • Options

    Well what happened was, I was using Vanilla 1 and I had to upgrade it to 2. Somehow through the transfer the guest role was missing. There is no default guest role at all. Also changing the permissions for any role is a bit tricky and buggy. Like for instance if I change any permission on a role, I also have to check SIGNIN, otherwise whenever someone is log in and they go on another page, they have to log back in again.

    Anyways I had to make a temporary "post a discussion" link (http://*****.com/post/discussion) somewhere on the forum and when a guest user clicks on it, they can use the fileupload. I tested it and it the uploading works even though Im a guest.

  • Options

    there is no role in the table called guests. like V says. guests are considered users who are not logged in.

    logged in users are traditionally called members.

    do you run the old vanilla 1 and vanilla2 in the same browser at the same time this will cause problems that sign you out, if so you need to change the cookie name in one of the config.phps so it uses a different cookie.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    vrijvlindervrijvlinder Papillon-Sauvage MVP
    edited June 2013

    It is strange that I was signed in at your site yet I could not post. As a guest I could not see the form at all. Even if you put a link to create a new discussion, the link has or should have a permission validator. In other words only those whom you gave permissions to upload or download can post or even see the form. The form also has permissions check.

    If you could take a screenshot of the roles page in your dashboard to see what you have ?
    role 1 is typically the admin, then 2 mod then 3 member and 4 is guest.

    Make sure Guest can't do anything not even view. That will make guests go directly to the sign in page if the click any link. Good way to test it.

  • Options

    @vrijvlinder said:

    If you could take a screenshot of the roles page in your dashboard to see what you have ?
    role 1 is typically the admin, then 2 mod then 3 member and 4 is guest.

    Here is the admin and member screen shot. I only have Admin, Member, VIP member, and Banned

  • Options

    Here is the bottom of the page for Admin and Member. Oh for Guest, I made that role yesterday because originally I didnt have it so I created one..but its not working. When I log out I can still see the forum and discussion form from that link (not in the discussions itself) but cannot make a post. If I need to screenshot something else, let me know.

  • Options
    vrijvlindervrijvlinder Papillon-Sauvage MVP

    Ok looks like the guest role is missing? Look at my dashboard so you can see what it should look like, notice there is nothing much to check in the guest role page.

  • Options

    I dont have that Guest role in the installement. I tried to create a Guest role but nothing changed...

  • Options
    vrijvlindervrijvlinder Papillon-Sauvage MVP
    edited June 2013

    ok try adding this line into your config.php to see of the role appears in your dashboard, it is just a test it may not work.

    $Configuration['Garden']['Registration']['DefaultRoles'] = array('8'); // The default role(s) to assign new users (4 is "Member")
    $Configuration['Garden']['Registration']['GuestRole']    = 6;
    
    
  • Options

    @vrijvlinder said:
    ok try adding this line into your config.php to see of the role appears in your dashboard, it is just a test it may not work.

    Would you know why I cant edit the config.php?
    I get this error:

    Response: 550 config.php: Permission denied
    Error: Critical file transfer error

  • Options
    vrijvlindervrijvlinder Papillon-Sauvage MVP

    550 error has to do with email smtp and relay of messages. If it does not allow you to write to the config.php it means you have bad permissions, it could also be why when you set roles they are not saved.

    make the permissions on the config.php 755 and see if that helps to write to it. Max is 775 do not use 777 it is dangerous opens to hackers.
    If you still can't then contact your host and ask them to set the correct permissions for you.

  • Options

    My host support wont be open for a couple of hours. I think that could be the main issue. Thanks vrijvlinder for your help so far!! I will get back to you soon!

Sign In or Register to comment.