Select the search type
  • Site
  • Web
Search
You are here:  Support/Forums
Support

Bring2mind Forums

PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 01/15/2007 11:31 PM by  Peter Donker
Bug with deleted documents
 10 Replies
Sort:
You are not authorized to post a reply.
Author Messages
Holger Kopf
New Member
New Member
Posts:57


--
01/09/2007 8:18 AM

    Hi, there is a bug in your application (version 03.04.08).

    If a user deletes a file it does not appear under the collection. BUT the deleted file can still be found if someone search for it !!!

    Regards Holger

    Peter Donker
    Veteran Member
    Veteran Member
    Posts:4536


    --
    01/10/2007 10:10 AM
    Holger,
    How were you logged in? Was it for a 'quick search' or an 'advanced search'? I can't replicate this for a regular user.
    Peter
    Holger Kopf
    New Member
    New Member
    Posts:57


    --
    01/10/2007 10:55 AM
    I logged in with a regular user, which has only read permission on DMX. I can see the deleted files (with the deleted icon) if i do a 'quick search' or a 'advanced search'.

    The user can download the file and see the meta data like:

    Approved Yes
    Locked No
    Private No
    Deleted Yes


    Peter Donker
    Veteran Member
    Veteran Member
    Posts:4536


    --
    01/10/2007 12:17 PM
    Holger,
    I cannot replicate this. I also think it would have been reported by many customers as this error you're experiencing is major. In the search code the deleted files are filtered out if the user is not an Admin/Host. I have no clue why this is not happening in your case. It looks like the system thinks the user is an admin (I just ask the DNN framework for this).
    Peter
    Holger Kopf
    New Member
    New Member
    Posts:57


    --
    01/10/2007 12:57 PM
    The user isn't a admin. how do you check the admin membership ? maybe the problem occurs only if dmx is in a sub-portal, like i use it....
    Could you pls. check it whithin a sub-portal ?
    Peter Donker
    Veteran Member
    Veteran Member
    Posts:4536


    --
    01/10/2007 3:14 PM
    Holger,
    I've done as you said and still it works correctly. Like I said, this error is too basic to have gone unnoticed. The records in DMX_Entries that have 'Deleted' set to True will not be shown to non-admin users.
    Peter
    Holger Kopf
    New Member
    New Member
    Posts:57


    --
    01/10/2007 4:01 PM
    very strange.
    i start a sql trace and see the following after starting a search:
    SELECT Roles.RoleName,
    Roles.RoleId
    FROM UserRoles
    INNER JOIN Users on UserRoles.UserId = Users.UserId
    INNER JOIN Roles on UserRoles.RoleId = Roles.RoleId
    WHERE Users.UserId = @UserId
    AND Roles.PortalId = @PortalId
    AND (EffectiveDate <= getdate() or EffectiveDate is null)
    AND (ExpiryDate >= getdate() or ExpiryDate is null)

    exec dbo.GetRoleByName @PortalId=1,@RoleName=N'Registered Users'
    exec dbo.GetRoleByName @PortalId=1,@RoleName=N'Subscribers'
    exec dbo.GetRoleByName @PortalId=1,@RoleName=N'TSG_B_DMS_Reader'

    exec dbo.DMX_GetCompletePortalEntryList @PortalId=1,@AllVersions=1


    As you can see the user is not in the Admin Group. How do you decide if a Role is the Admin-Role ?
    Peter Donker
    Veteran Member
    Veteran Member
    Posts:4536


    --
    01/10/2007 4:10 PM
    Either
    1. UserInfo.SuperUser = True
    or
    2. DotNetNuke.Security.PortalSecurity.IsInRole(CurrentPortalInfo.AdministratorRoleName)
    You can check these in the tables Users and Portals
    Peter Donker
    Veteran Member
    Veteran Member
    Posts:4536


    --
    01/10/2007 4:11 PM
    Note that in Portals the reference is to Admin Role ID which you then lookup in Roles to get a role name.
    Holger Kopf
    New Member
    New Member
    Posts:57


    --
    01/15/2007 1:46 PM
    After i uninstall your ADO Search AddOn, it works..... So something went wrong with acitve ADO Search option...
    Peter Donker
    Veteran Member
    Veteran Member
    Posts:4536


    --
    01/15/2007 11:31 PM
    Ah, you're using ADO search. Then I'd better go and check that one.
    Peter
    You are not authorized to post a reply.