Protecting sensitive information in Notes documents
Even in the most social businesses there is information that is available only on a "need to know" basis. Sometimes it is only a small subset of the fields in a document. In a Notes client, as long as I can see a document, I can see all the item values in it (using the document properties box), even if the field is hidden in the current form. So what are my options to protect a few sensitive fields?:
- Encrypt the fields with an encryption key that only the authorised user have. Problem here: you need to manage these keys and need a different set for each use case - messy. Also you can't show any of these fields in a view
- Hide the database design when applying the template. Looks good on the first view, but a semi skilled user can easily bypass that (e.g. copy & paste into an empty database, create a private view, use a @Prompt smart icon, use the free Document viewer or NotesPeek) - security by obscurity never works
- Store the sensitive data in a second document that is protected by reader names that are different (more restrictive) than the main document. This approach also keeps (given you have security set) curious admins out, a capability RDBMS is lacking
- Change the process and remove the need for the fine grained access control
tmp := @GetDocField(RiskAssessmentID;"RiskAssessment");
@If(@IsError(tmp);"nothing to retrieve";tmp)
Dim doc As NotesDocument
Dim riskDoc As NotesDocument
Dim uiDoc As NotesUIDocument
Dim db As NotesDatabase
Dim w As New NotesUIWorkspace
Set uidoc = w.CurrentDocument
Set doc = uidoc.Document
If doc.IsNewNote Then
Call doc.Save(True,True)
End If
Set db = doc.ParentDatabase
If doc.RiskAssessmentID(0) = "" Then
Set riskDoc = db.CreateDocument
Call riskDoc.ReplaceItemValue("Form","RAF")
Else
Set riskDoc = db.GetDocumentByUNID(doc.RiskAssessmentID(0))
If riskDoc Is Nothing Then
Set riskDoc = db.CreateDocument
Call riskDoc.ReplaceItemValue("Form","RAF")
End If
End If
Call riskDoc.MakeResponse(doc)
If w.DialogBox("RAF",True,True,False,False,False,False,"Please provide your Risk Assessment",riskDoc,True) Then
Call riskDoc.Save(True,True)
Call doc.ReplaceItemValue("RiskAssessmentID",riskDoc.UniversalID)
Call doc.Save(True,True)
End If
Call uidoc.Refresh
End Sub
Dim doc As NotesDocument
Dim riskDoc As NotesDocument
Dim db As NotesDatabase
Set doc = source.Document
If doc.RiskAssessmentID(0) = "" Then
Return
End If
Set db = doc.ParentDatabase
Set riskDoc = db.GetDocumentByUNID(doc.RiskAssessmentID(0))
Call riskDoc.ReplaceItemValue("Subject",doc.subject)
'Repeat with other fields needed in views, for workflow and access control
Call riskDoc.Save(True,True)
End Sub
Dim id As String
Dim Doc As NotesDocument
Dim parentDoc As NotesDocument
Dim db As NotesDatabase
Dim ws As New NotesUIWorkspace
Dim s As New NotesSession
id = Source.CaretNoteID
If id = "" Then
Continue = True
Exit Sub
End If
Set db = s.CurrentDatabase
Set doc = db.GetDocumentByID(id)
If Not doc.IsResponse Then
continue = True
Exit Sub
End If
continue = False
Set parentDoc = db.GetDocumentByUNID(doc.ParentDocumentUNID)
Call ws.EditDocument(False,parentDoc)
End Sub
XPages simply woud use 2 data sources and save us the trouble of building a dialog box.
As usual YMMV






Comments
IMHO this does not work with personal views, because they get generated and stored on the Notes Client. But "normal views" get created by the indexer which has access to all documents.
Removing the summary flag from secret items could help. Then they can't show up in views.
Posted by Karsten Lehmann At 17:29:02 On 11/05/2011 | - Website - |