ImageMovePopup context validation and security check¶
This operation resolves a Claim or Policy context number to display the worker's name (or "Confidential" if access is denied), enforces AD-group-based claim and image security, and optionally captures a notify task alongside confirming an image-move request.
| Field | Value |
|---|---|
| Operation ID | OP-3 |
| Trigger | Hosting page sets Active = True and ImageFileCode ("CLAIM" or otherwise treated as policy context). |
| Inputs | ImageFileCode, txtContextNum, txtNotifyID, wdteNotifyDate, txtNotifyText |
| Outputs | ConfirmAction(Confirm, ImageMoveEventArgs); public CheckImageSecurity/CheckClaimSecurity boolean/out-parameter authorization results |
| Primary components | ImageMovePopup.EditContext, ImageMovePopup.CheckClaimSecurity, ImageMovePopup.CheckImageSecurity, ImageMovePopup.SetSecurityUserImage, ImageMovePopup.EditAlertControls, ImageMovePopup.SaveButtonClick |
| Entry point | SAIF.Presentation.Web.Controls.PopUps.Infragistics111\ImageMovePopup.vb |
Steps¶
- On
txtContextNumTextChanged(auto-postback),RetrieveName()callsEditContext(). EditContext():- If
ImageFileCode = "CLAIM", callsGetClaimData()→clsClaimData.GetData(DataPortalInfo, contextNum)(referenced package call, not traced further)**. - If the claim is found, calls
CheckClaimSecurity(MyClaimData.Security, String.Empty, AccessAllowed, LastError)(BR-IMG-001):- Domain gate: if
mySecurity.Domain <> "SAIF", denies unconditionally (BR-IMG-004). - Else evaluates up to 4 claim-security flags (
IsConflict,IsExposure,IsHealthIssue,IsHostileWorker) against the corresponding AD resources (BR-IMG-002, BR-IMG-003). - On failure of any check, masks the worker's name as
"Confidential"and setsErrorMsg.
- Domain gate: if
- Otherwise (non-
"CLAIM"context), callsGetPolicyData()→clsPolicyData.GetPolicyData(DataPortalInfo, policyNum)and showsMyPolicyData.PolicyNameif found, elseMSG_WAR_NO_POLICY; no analogous security check exists for the policy path*. EditAlertControls()validates the optional notify task (BR-POPUP-003):- If
txtNotifyTexthas content,txtNotifyIDmust also be non-empty (elseMSG_ENTER_VALID_NOTIFY_ID). - A non-empty
wdteNotifyDatecannot be earlier than today (elseMSG_NOTIFY_DATE_PRIOR_TO_TODAY). Render()callsSetSecurityUserImage()to populate theImageSecuritycached-flags structure fromclsSecurityPrincipal.IsAuthorized(...)for eachADSG_*resource name; the resultingmyImageSecurityfields are not observed to gate any rendering decision beyond population**. The popup is then positioned and rendered.- On
cmdSaveclick,SaveButtonClick()re-runsEditContext()thenEditAlertControls(); only if both succeed does it raiseConfirmAction(True, New ImageMoveEventArgs(contextNum, notifyID, notifyDate, notifyText)). - On
cmdCancelclick, raisesConfirmAction(False, ...)with current field values and callsResetControls(). - Public method
CheckImageSecurity(inImageFileCode, inMailId): - Returns
Trueunconditionally for a fixed allow-list of system mailboxes (BR-IMG-005). - If
inMailIdequals the current user, returns the cachedmyImageSecurity.HasImageflag (BR-IMG-006). - Otherwise, delegates to
ImageServices.HasADAccessToImageResource(inImageFileCode, inMailId)(external/referenced call, not traced further)**.
Process flow¶
The following diagram visualizes the context validation and security check flow.
flowchart TD
Start([txtContextNum TextChanged]) --> Edit[EditContext]
Edit --> Type{ImageFileCode = CLAIM?}
Type -->|Yes| Claim[GetClaimData]
Claim --> Sec[CheckClaimSecurity]
Sec --> Domain{Domain = SAIF?}
Domain -->|No| Deny([Deny outright])
Domain -->|Yes| Flags{Any claim flag fails resource check?}
Flags -->|Yes| Mask([Show Confidential, set ErrorMsg])
Flags -->|No| ShowName([Show worker name])
Type -->|No| Policy[GetPolicyData, show PolicyName]
ShowName --> Alert[EditAlertControls validates notify fields]
Mask --> Alert
Policy --> Alert
Alert --> Save{cmdSave clicked}
Save -->|Valid| Confirm([ConfirmAction True with ImageMoveEventArgs])
Save -->|Invalid| Blocked([Popup stays active, ErrorMsg shown])
Failure and edge-case behavior¶
- Non-
"SAIF"-domain callers are denied claim access unconditionally, independent of the 4 flag-level checks (BR-IMG-004). - When claim access is denied,
EditContext()sets the UI-boundErrorMsgto the genericMSG_WAR_NO_CLAIMrather than the more specificMSG_NOT_AUTH_CLAIM/LastErrorvalue returned byCheckClaimSecurity— whether this is intentional is unconfirmed*. - The policy-context branch performs no equivalent ownership/security check before displaying
MyPolicyData.PolicyName*.
Related documentation¶
Sources¶
SAIF.Presentation.Web.Controls.PopUps.Infragistics111\ImageMovePopup.vbSAIF.Presentation.Web.Controls.PopUps.Infragistics111\ImageMovePopup.ascx