Summary
Frappe LMS contains an authorization flaw that can let a Batch Evaluator act on certificate evaluations outside their assigned scope. If the evaluator can call the exposed certificate-creation method with another evaluation's name, they may issue certificates for unassigned evaluations or learners outside their batches.
Affected context
The issue concerns the LMS Certificate Evaluation doctype and the whitelisted create_lms_certificate method. It becomes relevant in deployments where Batch Evaluators can invoke this method and the application does not independently verify that the requested evaluation and learner are within the evaluator's authorized batch scope.
Exploit preconditions
- Attack surface: The whitelisted certificate-creation method
- Required access: An account with Batch Evaluator privileges
- Trigger point: A request to create a certificate for a specified evaluation
- Why exploitation is possible: The doctype lacks a permission-scoping hook to enforce that the evaluator is authorized for the named evaluation and learner
Why this happens
The application does not adequately enforce authorization for certificate evaluation records. Without a permission check scoped to the evaluator's assigned batches, a request can be accepted based on the caller's general role rather than their authorization for the specific object. This is an instance of CWE-862: Missing Authorization.
Potential impact
- Batch Evaluators may be able to issue certificates for evaluations outside their assigned scope.
- Learners who are not part of an evaluator's batches could receive certificates without authorization.
- Certificate records may become inaccurate, potentially affecting academic or administrative decisions.
General mitigation guidance
Defensive patterns include enforcing object-level authorization on every certificate-creation request and checking batch membership for both the evaluation and learner on the server side. Permission checks should be applied consistently across whitelisted methods and doctype operations, with access denied by default when ownership or scope cannot be established. Limiting evaluator privileges to the minimum necessary and auditing certificate issuance can further reduce risk.
How teams detect issues like this
Review whitelisted methods and doctype permission logic for operations that accept record names or identifiers without verifying caller access to those specific records. Check whether authorization is enforced server-side for both evaluations and learners, rather than relying only on interface controls or broad role checks. Policy checks and automated code review can flag sensitive methods that lack object-level authorization; audit logs can help identify certificate creation outside expected batch assignments.

