Can anonymous visitors read the comments under the unposted articles?

📅 October 9, 2026 Eye 10

Can the comments under an unpublished article be read by anonymous visitors, regardless of whether this article has been published or not, and whether the interface for reading comments has judged visibility separately? A common misconception is that 'the main text is not visible to the public, so the comments are also not visible'—on the contrary, the main text and its attached comments and messages are two independent layers of data. The visibility of the parent object does not automatically make the child object invisible. A mainstream program specifically fixed an issue in its security version in October 2026, which was a typical example of this missed judgment: 'private and unpublished article comments being read without authorization.'

Why is this kind of question appearing in comments instead of in the main text

The visibility of the main text is the easiest to handle: list queries are naturally filtered by status, drafts and pending publications never appear in the external list, and direct access to the address of an unpublished main text is usually blocked by the status verification. The trouble lies in the fact that comments are a separate set of records, with their own list interfaces and detail interfaces. The list interface often filters with 'only comments under published main texts', while the detail interface usually retrieves data based on the comment's own ID, without checking the status of the article it belongs to at the moment. An anonymous visitor can bypass the main text gate by simply obtaining a comment ID.

When the parent object is not visible, who should the child object follow?

The principle is only one sentence: the child object does not inherit the visibility of the parent object, it must check the status of the parent object again at the moment of reading. When it comes to the order of judgment, reading a comment should first locate which document it belongs to, and then see if the document is a draft, pending publication, official, or recycling bin, and only when the main text is visible to the outside, the comment content will be returned accordingly. Reversing this order will result in contradictory results such as 'Main text 403, comment 200'.

What will happen if the details of the verification list are omitted?

List and detail are two code paths, the vulnerability is almost always on the one written later.

Read path Whether to check the status of the main text Anonymous visible Consequences
Comment list (hanging under the published article) Is Only published As expected
Single comment detail (by ID) Commonly missed May read comments under the main text that has not been published Access violation
Pending review messages Yes + review status No Content review required
Preview of draft text With preview parameters Within the authorized session Preview parameters are not passed to the message interface

The critical line is the second line: The detail interface only recognizes comment ID, and when the parent document status is not checked back, the comments under the unissued article become public detours. The same fix also includes a stored XSS triggered by the pending review comments on the comment management page, which reminds us of another thing - messages not only can be read, but may also be written back to the management interface for execution, so content review and sensitive word filtering should take effect on the write side.

How to express visibility in the document status model within the site

The Aanqi CMS divides documents into four states: formal documents, drafts, pending release, and recycle bin. The draft link with preview parameters can be previewed in authorized sessions. Deleting a formal document is moved to the recycle bin instead of being physically deleted. This set of states itself is the basis for visibility judgment: any read interface should take the current status of the target document as a prerequisite before returning content, rather than assuming that the caller will only enter from the external list.

How should the message and comment interface be divided into three layers

Refer to the API call surface, interfaces such as comments and reviews need to pass three stages: the first is the parent document status (whether formal, whether visible to the public), the second is the child record's own status (whether reviewed, whether marked as spam), and the third is the role and permission (unlogged-in users can see approved ones, authors can see their own related ones, pending ones are only given to review roles). The most easily overlooked is the reuse of the second and third layers for detail interfaces.

Self-check in three steps

First, create a document to be published, leave a reviewed comment below it; then, use an unlogged session to directly request the details interface of the comment, to see if the result is empty or complete; finally, check whether the same interface rejects reading for the recycling bin and unreviewed comments. If the second step returns content, it means that the visibility check is missing in the details path.

Common questions

Question: Can't we just hide the draft content address?Answer: Not enough. Comments have an independent reading entry, even if no one knows the content address, the comment ID will be exposed when enumerated, and the closure should be on the interface status verification.

Ask: Can't we just preview the parameters to see the comments?Answer: The preview parameters are for the main content preview, and the comment interface does not recognize this parameter, which is the point to check - if it recognizes it, it will expand the scope, and not recognizing it is in line with 'determine according to the document status'.

Ask: Can the content review prevent this kind of overstepping?Answer: The review manages whether the comment content can be published externally, while overstepping manages whether the article it belongs to can be published externally. These two things should be judged separately, and cannot rely on the review to cover all aspects.

Related articles

Which fields can the access log record, and how to write the content received from the client in a secure way?

The field of the access log is composed of format instructions and is not a fixed table structure. The source address, request line, status code, and time consumption come from the server side, and the source path and client identifier are provided by the requestor and can be forged. Writing to the client可控 fields must depend on escaping: The default escaping will handle double quotes, backslashes, and control characters, and variables that cannot be retrieved are marked with hyphens. The log configuration determines whether it is for the entire site or by path, deciding whether it can be distinguished in a multi-site scenario.

2026-10-09

After changing the domain name, should the verification file submitted to the search engine be placed again?

To be placed again. The purpose of the key and the verification file is to prove the ownership of the current domain and host, which is bound to the 'current site', not the machine that was uploaded initially. After changing the domain name, it should be placed again in the root directory of the new domain name or in a publicly accessible folder on the same host and re-verified. At the same time, the 301 jump, sitemap, and in-site link push queue from the old domain name to the new domain name should be rearranged separately - the jump relationship and the communication channel are two different things.

2026-10-09

Is the multilingual site translated as a whole page or filled in field by field, how much is the maintenance difference

Full-page translation generates a complete page at one time, saving labor on the initial generation, but the cost is in the subsequent changes to the source page; manual entry of each field is more controllable, with labor spent on each change. The basis for judgment is not which is more advanced, but the frequency of revision and the number of sites: columns with frequent changes in source content are suitable for field-by-field, long-tail articles and brand site expansion are suitable for full-page generation followed by proofreading, and when multiple sites share a backend, it is necessary to clarify the maintenance boundaries first.

2026-10-09

How should the strength and error lock of the password recovery verification code be configured?

The verification codes for password recovery, login verification, and form anti-robot verification are not the same thing: recovery type requires random source sufficient, short validity period, error count lock binding to the same entry; form type requires blocking batch submission, which can be handed over to interactive verification such as reCAPTCHA. The same CMS has also strengthened in the recent version updates in this direction, changing the verification code to 6-digit secure random generation and adding expiration time and error count lock.

2026-10-09

What should be written after each link in the documentation file for the large model site?

In the site description document for large models, only the project name is required, and the rest of the paragraphs are organized as agreed. Each link entry is written as a bracket name followed by a parenthesis address, which may optionally be followed by a colon and a sentence of explanation. This explanation should not repeat the title but should state what the page answers, who it is for, and the date it was last updated; the sitemap and keyword library are responsible for the other half of the clues.

2026-10-09

What should the AI engine provide when it needs the whole site content list, the site map and the model description file respectively?

The site map and the description file for large models do not answer the same question. The site map is an address list, providing URL, last modified time, and priority, aimed at general web crawlers; the model description file is a semantic list, using grouping and each summary to describe what this page is about and who it is for, aimed at language models. Both are automatically generated by the system, and the entry and summary are manually maintained.

2026-10-09

Can an editor account change the homepage display position, and how should role permissions be restricted?

Can authors or editors change the homepage display position, restricted by 'ability impact range' instead of headcount? Actions affecting the entire site's display should not be given to submission roles. A mainstream program in the security version of October 2026 listed 'author role can execute pinned articles' as a vulnerability fix. The site sets the accessible range according to user groups and group permissions, and high-risk site-level interfaces are not open by default.

2026-10-09

Is upgrading the backend frontend dependency library a security maintenance action?

The built-in script library and upload component are also on the attack surface, determine whether a dependency upgrade is a safe action, see if it is written in the same release as the vulnerability repair, and whether it covers the known vulnerability range. A peer program in the September 2026 version wrote the upgrade of the background jQuery and upload component and 'repairing known security vulnerabilities of the old version' in the same announcement. Backup before upgrading, and check the version number and behavior after upgrading.

2026-10-09