Skip to content

rvt-mcp v2.5.3

Latest

Choose a tag to compare

@lekhoa221 lekhoa221 released this 06 Dec 03:11
· 10 commits to master since this release
bf47ce0

Security hardening, parameter unit conversion fixes, inline view-image capture, startup crash fixes, and public docs standardization.

  • Catalog counts: --toolsets all 257, adaptive bake 260, bare defaults 63, and --read-only 105.

Parameter units and project unit inspection

  • Fix #80: revit_set_element_parameter_values, revit_set_type_parameter_values, and revit_set_parameter_value_by_guid now classify Revit parameter ForgeTypeId specs via a shared resolver (ParameterSpecResolver + UnitUtils.GetValidUnits fallback) into six canonical kinds (length, area, volume, angle, dimensionless, unmapped_physical). Length-family MEP and structural specs (PipeSize, DuctSize, PipeInsulationThickness, DuctInsulationThickness, CableTraySize, ConduitSize, BarDiameter, WireDiameter, SectionDimension, Roughness, Displacement, etc.) now default to millimeters on plain double inputs instead of falling back to Revit internal feet.
  • Unify plain double defaults across all parameter writers (mm for length-family, m2 for area, m3 for volume, deg for angle), extend inline unit overrides to both Metric and Imperial tokens, and add clear guidance for compound feet-inches strings and decimal commas.
  • Support explicit valueType="display" (Revit native Parameter.SetValueString using project units/locale) and valueType="internal" (raw Revit internal double, no conversion) across all three generic parameter setters; reject plain doubles on unmapped physical specs (Slope, Flow, Pressure, etc.) and reject conflicting unit overrides when valueType is display or internal.
  • Add canonical metric readback (canonicalValue / canonicalUnit) alongside rawValue and displayValue in revit_get_element_parameters and revit_get_type_parameters, and return specId/specKind on parameter-write results.
  • Route revit_create_view_filter, revit_workflow_data_roundtrip, revit_get_titleblock_parameters, revit_set_titleblock_parameters, revit_list_family_types_in_family, revit_get_schedule_definition, revit_apply_schedule_filter_sort, and revit_create_schedule through the shared ParameterSpecResolver.
  • Migration note for revit_workflow_data_roundtrip: CSV/JSON files exported by v2.5.2 stored MEP length columns (PipeSize, DuctSize, etc.) in raw Revit feet without unit metadata. Re-export data before importing after this upgrade (or run with dryRun: true first).
  • Expose project display units on inspection: revit_health reports display_unit_system (Metric/Imperial), and revit_get_document_state adds a units block with display_unit_system and per-spec FormatOptions.

Query, filtering, view capture, and UI

  • Return revit_capture_view_image inline as an MCP ImageContentBlock alongside JSON metadata when include_image=true (default) and the encoded payload fits the transport cap, with CaptureOutputPath allowlist/symlink validation, bounded streaming reads, SHA-256 verification, and ImageFileType.JPEGMedium for JPEG captures. From #85; thanks @loranasaad.
  • Fix #77 (#79): revit_ai_element_filter resolves category names against top-level categories first, fixes empty-value and unknown-parameter bypasses, and adds viewSpecific.
  • Improve update-notice layout and trigger a 30-minute cooldown update check when opening History or Reports (#76).

Security, transport, and reliability hardening

  • Enforce ExportPathPolicy across export, import, shared-parameter, family, and workflow path handlers (rejecting UNC, device, wildcard, ADS, symlink/junction traversal, and writes to protected directories) (#92).
  • Fail closed on corrupt rvtmcp.config.json (read-only with send_code and ToolBaker disabled, reporting CONFIG_CORRUPT in revit_health) (#92).
  • Harden ToolBaker startup gates, baked-tool path confinement, and compiler policy (LINQ-to-Objects only); enforce --toolsets / --read-only / --disable-* across revit_batch_execute sub-commands (TOOL_DISABLED) and reject list_baked_tools when ToolBaker is disabled (TOOLBAKER_DISABLED) (#92).
  • Harden CSV parsing per RFC 4180 in revit_workflow_data_roundtrip with category/instance validation and 64 MiB cap, plus spreadsheet formula neutralization in exported CSVs (#92).
  • Restrict Revit 2025-2027 Named Pipe connections to the same Windows user and elevation level (CurrentUserOnly), isolate IPC mutexes to Local\, cancel queued requests on client disconnect, and bound NDJSON wire line reads (BoundedLineReader) (#81, #92).
  • Remove the --http transport mode so rvt-mcp runs over stdio only, dropping Microsoft.NET.Sdk.Web and ModelContextProtocol.AspNetCore from RvtMcp.Server (#93).
  • Reject unknown arguments on write and safety-scoped tool calls before dispatch (ToolArgumentGuard) and unload revit_send_code_to_revit dynamic assemblies via collectible AssemblyLoadContext (#81).
  • Fix #90 (#91): skip bulk failure text formatting at startup and scope the Revit failure message catalog cache by build and language to prevent add-in startup crashes.
  • Add configurable failureElementIndexLimit with receipt truncation diagnostics (#89).
  • Standardize multilingual READMEs and public docs to BW-DOC-001 (#82), update SECURITY.md for Private Vulnerability Reporting (#87), and publish the live security hardening verification record in docs/testing/2026-12-05-security-hardening-live.md (#94).

Credits

Distribution

Setup includes the self-contained Windows x64 gateway and Revit 2022-2027 plugins. NuGet (RvtMcp.Server) contains the gateway only and requires .NET 10. The Claude Desktop MCPB is unsigned and requires the exact Setup gateway SHA-256 (5d362270bc073de976067dc9e84d9da4674e3366b3c3fa53c486c8e728a80b44), including executable overrides. All three packages include SHA-256 sidecars.

Validation

  • CI run 47557182344 on master (bf47ce0): changes, public-tree, tests-xunit (4525/4525), installer-powershell, installer-pwsh, plugin-R22 to plugin-R27, server-nuget, client-setup-zip, and ci-ok all passed.
  • Additional local UI and contract suites: RvtMcp.Reports.Tests (30/30), RvtMcp.Settings.Tests (28/28), RvtMcp.Toast.Tests --position-layout, check-readme-contract.ps1 / readme-contract.Tests.ps1 (19/19), check-public-tree.Tests.ps1, and test_verify_package.py (11/11).
  • Packaged Setup ZIP verification (verify-package.py) on 2.5.3+bf47ce05eeae0a764fa3a0e856cf18f6a4f2a99c: checksum sidecar and 14-file manifest integrity passed; disposable smoke checks passed for default (63 tools) and --toolsets all (257 tools).
  • MCPB catalog capture and validation on 2.5.3+bf47ce05eeae0a764fa3a0e856cf18f6a4f2a99c: template suite 23/23 passed, 260 tools (--toolsets all --enable-adaptive-bake), schema SDK 1.27.1 PASS, @anthropic-ai/mcpb@2.1.2 validate and pack PASS.
  • Live Revit verification: security hardening live matrix (docs/testing/2026-12-05-security-hardening-live.md) across TCP and Named Pipe hosts, plus live inline capture verification on Revit 2022 and Revit 2027.

Source commit: bf47ce05eeae0a764fa3a0e856cf18f6a4f2a99c.