AI Slop Code Risk Monitor

stalwartlabs/stalwart

SlopCodeMonitor badge for stalwartlabs/stalwart Adjusted legacy signal; badge bands: 25 / 50 / 75 (different from dashboard bands).

All-in-one Mail & Collaboration server. Secure, scalable and fluent in every protocol (IMAP, JMAP, SMTP, CalDAV, CardDAV, WebDAV).

1.1 Low pattern signal View on GitHub

Open-Source Code Quality, Security and Technical Debt Review

This report summarizes scanner evidence for stalwartlabs/stalwart, a Rust project with 15,565 GitHub stars. SynthScan examined 557,125 lines of code across 1672 source files, recording 278 pattern matches distributed across 11 syntactic categories. The legacy adjusted pattern signal is 1.1 (Low pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

1.1
Adjusted Signal
1.1
Raw Pattern Score
100%
Time Factor
2026-10-28
Last Push
15.6K
Stars
Rust
Language
557.1K
Lines of Code
1.7K
Files
278
Pattern Hits
2026-10-31
Scan Date
0.02
HC Hit Rate

Risk Review · Payload v1

Use each vector to guide manual verification of the underlying findings.

Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.

Cognitive Ownership Risk 1.9/100 · LOW

Can maintainers explain intent, assumptions, and trade-offs? 224 finding(s).

Hallucinated Dependency & Supply Chain Risk 3.3/100 · LOW

Are imports declared and package/API names verified? 44 finding(s).

Agent Over-Engineering Ratio 0.2/100 · LOW

Are wrappers, guards, and repeated structures necessary? 13 finding(s).

PR Review Velocity Impact 5.4/100 · LOW

Which changes need focused human review? 278 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 36HIGH 1MEDIUM 6LOW 235

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 278 distinct pattern matches across 11 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Hallucination Indicators36 hits · 360 pts
SeverityFileLineSnippetContext
CRITICALcrates/imap/src/core/mailbox.rs115 verified_at: self.server.inner.cache.revalidate.now(),CODE
CRITICALcrates/imap/src/core/mailbox.rs228 if !self.server.inner.cache.revalidate.is_within(verified_at) {CODE
CRITICALcrates/imap/src/core/mailbox.rs289 let verified_at = self.server.inner.cache.revalidate.now();CODE
CRITICALcrates/imap/src/op/list.rs229 mailbox_name: self.server.core.email.shared_folder.as_str().into(),CODE
CRITICALcrates/imap/src/op/create.rs229 if path.first() == Some(&self.server.core.email.shared_folder.as_str()) {CODE
CRITICALcrates/imap/src/op/copy_move.rs532 Some(is_spam) if self.server.core.spam.classifier.is_some() => Some(CODE
CRITICALcrates/imap/src/op/namespace.rs28 Some(self.server.core.email.shared_folder.as_str().into())CODE
CRITICALcrates/spam-filter/src/analysis/domain.rs56 email.element.email.domain_part.fqdn.clone(),CODE
CRITICALcrates/spam-filter/src/analysis/score.rs260 if acc.decision().is_none() && !self.core.spam.rules.after_ai.is_empty() {CODE
CRITICALcrates/spam-filter/src/modules/expression.rs200 ExpressionVariable::FromDomain => output.from.email.domain_part.fqdn.as_str().into(),CODE
CRITICALcrates/common/src/auth/access_token.rs62 UserRoles::User => self.core.network.security.default_role_ids_user.as_slice(),CODE
CRITICALcrates/common/src/auth/access_token.rs75 self.core.network.security.default_role_ids_admin.as_slice()CODE
CRITICALcrates/common/src/auth/access_token.rs191 .unwrap_or(self.core.network.security.default_role_ids_group.as_slice());CODE
CRITICALcrates/common/src/auth/permissions.rs121 UserRoles::User => self.core.network.security.default_role_ids_user.as_slice(),CODE
CRITICALcrates/common/src/auth/permissions.rs134 self.core.network.security.default_role_ids_admin.as_slice()CODE
CRITICALcrates/common/src/auth/permissions.rs144 .unwrap_or(self.core.network.security.default_role_ids_group.as_slice()),CODE
CRITICALcrates/common/src/auth/rate_limit.rs131 self.core.network.http.rate_authenticated.is_some() && is_remote,CODE
CRITICALcrates/common/src/auth/oauth/cimd.rs90 self.core.network.resources.registrable_domain.as_deref(),CODE
CRITICALcrates/common/src/network/security.rs438 self.core.network.security.auth_fail_rate.is_some()CODE
CRITICALcrates/common/src/network/dns/update.rs1301 match self.core.smtp.resolvers.dns.txt_raw_lookup(&name).await {CODE
CRITICALcrates/common/src/scripts/plugins/lookup.rs32 _ => Some(ctx.server.core.storage.memory.clone()),CODE
CRITICALcrates/common/src/scripts/plugins/lookup.rs61 _ => Some(ctx.server.core.storage.memory.clone()),CODE
CRITICALcrates/common/src/scripts/plugins/lookup.rs85 _ => Some(ctx.server.core.storage.memory.clone()),CODE
CRITICALcrates/common/src/scripts/plugins/query.rs25 _ => Some(ctx.server.core.storage.data.clone()),CODE
CRITICALcrates/http/src/request.rs285 self.core.network.http.url_https.to_string(),CODE
CRITICALcrates/http/src/request.rs1023 if !server.core.network.http.response_headers.is_empty() {CODE
CRITICALcrates/http/src/request.rs1041 if server.core.network.http.remote_ip_source.is_peer() {CODE
CRITICALcrates/http/src/auth/oauth/authorize.rs415 .unwrap_or_else(|| server.core.network.http.url_https.clone());CODE
CRITICALcrates/http/src/auth/oauth/openid.rs100 let issuer = if strip_base_url && !self.core.network.http.url_https.is_empty() {CODE
CRITICALcrates/smtp/src/inbound/data.rs538 let message_id = self.server.inner.data.queue_id_gen.generate();CODE
CRITICALcrates/smtp/src/inbound/data.rs703 .set_variable("spam.is_spam", self.server.core.spam.scores.is_spam(score));CODE
CRITICALcrates/jmap/src/registry/mapping/action.rs253 set.server.inner.data.applications.reload(&mut bp).await;CODE
CRITICALcrates/jmap/src/registry/mapping/action.rs471 let (score, disposition) = match server.core.spam.lists.scores.get(&tag) {CODE
CRITICALcrates/jmap/src/registry/mapping/log.rs36 let Some(path) = get.server.core.metrics.log_path.clone() else {CODE
CRITICALcrates/jmap/src/registry/mapping/log.rs76 let Some(path) = req.server.core.metrics.log_path.clone() else {CODE
CRITICALcrates/jmap/src/api/session.rs42 VecMap::with_capacity(self.core.jmap.capabilities.account.len() + 1);CODE
Over-Commented Block207 hits · 190 pts
SeverityFileLineSnippetContext
LOWinstall.sh241# Uncomment and edit an entry to override its default.COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1/*COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs581 /// When the rule has a non-empty number of BYDAY values, then thisCOMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs621 }COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs761 })COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs781 .by_week_dayCOMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs801 let start = dt.first_of_month();COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs861 /// where all the goods are.COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1001 // since we filter based on `until` when we pop from theCOMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1021 .tz()COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1041 // You'll never get back to a leap day. So instead, we track ourCOMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1421 ///COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1641 continue;COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1661}COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1681/// fn into_integer_iter(self) -> impl Iterator<Item = Self::Integer>;COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1701/// * A single integer: `5`COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1721pub trait IntoI16Iter {COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1741///COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs1901///COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs2021 }COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs2061COMMENT
LOWcrates/calcard/src/datecalc/recurrence.rs2081 ByWeekday::Any(weekday) => Either::Left(iter_weekdays_between(weekday, start, end)),COMMENT
LOWcrates/calcard/src/datecalc/weekdate.rs21#[derive(Clone, Copy, Debug)]COMMENT
LOWcrates/calcard/src/datecalc/weekdate.rs141///COMMENT
LOWcrates/calcard/src/datecalc/weekdate.rs161 // > calendar year is the first week that contains at least four (4) daysCOMMENT
LOWcrates/calcard/src/common/format.rs321#[cfg(all(test, stalwart_tests))]COMMENT
LOWcrates/calcard/src/common/tzdb.rs1/*COMMENT
LOWcrates/calcard/src/common/timezone.rs21/// A reference to the time zone a calendar value is interpreted in.COMMENT
LOWcrates/calcard/src/icalendar/timezone.rs701#[cfg(all(test, stalwart_tests))]COMMENT
LOWcrates/calcard/src/icalendar/builder.rs761#[cfg(all(test, stalwart_tests))]COMMENT
LOWcrates/smtp-report/src/lib.rs1/*COMMENT
LOWcrates/smtp-report/src/lib.rs41pub struct ReportEnvelope<'x> {COMMENT
LOWcrates/smtp-report/src/arf/generate.rs21use std::{fmt::Write, io, time::SystemTime};COMMENT
LOWcrates/smtp-report/src/arf/generate.rs281#[cfg(all(test, stalwart_tests))]COMMENT
LOWcrates/smtp-report/src/arf/mod.rs1/*COMMENT
LOWcrates/smtp-report/src/arf/mod.rs21use std::{borrow::Cow, net::IpAddr};COMMENT
LOWcrates/smtp-report/src/arf/mod.rs41 /// `Authentication-Results` field.COMMENT
LOWcrates/smtp-report/src/arf/mod.rs61 pub source_ip: Option<IpAddr>,COMMENT
LOWcrates/smtp-report/src/arf/mod.rs81 pub dkim_canonicalized_body: Option<Cow<'x, str>>,COMMENT
LOWcrates/smtp-report/src/arf/mod.rs141 /// Both mechanisms produced an aligned identifier (`dkim, spf`).COMMENT
LOWcrates/smtp-report/src/arf/mod.rs161 Other,COMMENT
LOWcrates/smtp-report/src/arf/parse.rs41 .and_then(|offset| source.get(offset..offset + bytes.len()))COMMENT
LOWcrates/smtp-report/src/tlsrpt/generate.rs21struct ReportHeader {COMMENT
LOWcrates/smtp-report/src/tlsrpt/generate.rs41 /// Fields read from `envelope`:COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs41 pub contact_info: Option<String>,COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs61COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs81 #[serde(rename = "policy-string")]COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs101 #[serde(rename = "total-successful-session-count")]COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs121 #[serde(rename = "sending-mta-ip")]COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs141 /// Number of sessions that failed this way (`failed-session-count`).COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs161pub struct DateRange {COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs181 #[serde(rename = "sts")]COMMENT
LOWcrates/smtp-report/src/tlsrpt/mod.rs201 #[serde(rename = "certificate-host-mismatch")]COMMENT
LOWcrates/smtp-report/src/tlsrpt/parse.rs21 /// `result-type` values map to the `Other` variant.COMMENT
LOWcrates/smtp-report/src/dmarc/generate.rs21use mail_builder::{MessageBuilder, headers::HeaderType, mime::make_boundary};COMMENT
LOWcrates/smtp-report/src/dmarc/generate.rs41 /// the file name.COMMENT
LOWcrates/smtp-report/src/dmarc/generate.rs61 /// },COMMENT
LOWcrates/smtp-report/src/dmarc/generate.rs81 /// },COMMENT
LOWcrates/smtp-report/src/dmarc/generate.rs101 /// };COMMENT
LOWcrates/smtp-report/src/dmarc/mod.rs1/*COMMENT
147 more matches not shown…
Excessive Try-Catch Wrapping10 hits · 16 pts
SeverityFileLineSnippetContext
LOWresources/scripts/ossify.py70 except Exception as e:CODE
MEDIUMresources/scripts/ossify.py71 print(f"Error reading file {file_path}: {e}")CODE
LOWresources/scripts/ossify.py167 except Exception as e:STRING
MEDIUMresources/scripts/ossify.py205 print(f"Error: {args.directory} is not a valid directory")STRING
LOWresources/scripts/migrate_v016.py1810 except Exception as exc:CODE
MEDIUM⚡resources/scripts/imap-log-sanitizer.py132 print(f"Error: File '{args.input_file}' not found")CODE
LOW⚡resources/scripts/imap-log-sanitizer.py134 except Exception as e:CODE
MEDIUM⚡resources/scripts/imap-log-sanitizer.py135 print(f"Error reading file: {e}")CODE
LOWresources/scripts/imap-log-sanitizer.py159 except Exception as e:CODE
MEDIUMresources/scripts/imap-log-sanitizer.py160 print(f"Error writing output: {e}")CODE
Deep Nesting8 hits · 8 pts
SeverityFileLineSnippetContext
LOWresources/scripts/ossify.py23CODE
LOWresources/scripts/ossify.py92CODE
LOWresources/scripts/ossify.py131CODE
LOWresources/scripts/ossify.py183CODE
LOWresources/scripts/migrate_v016.py840CODE
LOWresources/scripts/list_active_blobs.py92CODE
LOWresources/scripts/list_active_blobs.py48CODE
LOWresources/scripts/imap-log-sanitizer.py102CODE
Structural Annotation Overuse4 hits · 6 pts
SeverityFileLineSnippetContext
LOWUPGRADING/v0_16.md76## Step 1: Convert existing settings into a configuration snapshotCOMMENT
LOWUPGRADING/v0_16.md149## Step 2: Back up the databaseCOMMENT
LOWUPGRADING/v0_16.md213## Step 3: Perform the migrationCOMMENT
LOWUPGRADING/v0_16.md460## Step 4: Post-migration tasksCOMMENT
Fake / Example Data4 hits · 4 pts
SeverityFileLineSnippetContext
LOWcrates/smtp-report/src/dmarc/generate.rs105 /// to: vec!["dmarc-reports@example.org"],COMMENT
LOWcrates/text-extract/src/odf.rs161 (true, b"placeholder") => value == b"true",CODE
LOWcrates/main/src/test_data.rs146 address: "bob@example.org".into(),CODE
LOWcrates/main/src/test_data.rs166 orcpt: Some("bob@example.org".into()),CODE
AI Slop Vocabulary1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUMcrates/smtp/Cargo.toml60#harness = falseCOMMENT
Unused Imports3 hits · 3 pts
SeverityFileLineSnippetContext
LOWresources/scripts/ossify.py18CODE
LOWresources/scripts/migrate_v016.py29CODE
LOWresources/scripts/imap-log-sanitizer.py13CODE
Hyper-Verbose Identifiers3 hits · 2 pts
SeverityFileLineSnippetContext
LOWresources/scripts/ossify.py92def remove_proprietary_snippets(content: str) -> Tuple[str, int]:STRING
LOWresources/scripts/migrate_v016.py953 def _tenant_default_domain_cid(self, p: dict[str, Any]) -> str | None:CODE
LOWresources/scripts/migrate_v016.py1287 def _is_same_kv_store_as_data(self, sub: dict[str, str]) -> bool:CODE
Cross-Language Confusion1 hit · 2 pts
SeverityFileLineSnippetContext
HIGHresources/scripts/repair_fdb_chunks.py6extra chunk, suffixed with a single byte: `key`, `key || 0x00`, `key || 0x01`,STRING
Redundant / Tautological Comments1 hit · 2 pts
SeverityFileLineSnippetContext
LOWinstall.sh969# Check if curl supports the --retry flag, then pass it to the curl invocation.COMMENT