Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f9e2a82eec | ||
|
|
b8826f542e | ||
|
|
8465c84f6e | ||
|
|
edfb1007bb | ||
|
|
46a3767f6e | ||
|
|
d1c85687ad | ||
|
|
469da888d7 |
No files matched your search
@@ -0,0 +1,50 @@
|
||||
name: CodeQL
|
||||
|
||||
# Advanced setup in place of CodeQL default setup, which never analyses Dependabot pull requests: the required
|
||||
# `Analyze (...)` checks never reported there, so they could not be merged. Same languages, build mode, default query
|
||||
# suite and `/language:` categories as default setup, so existing alerts carry over. Default setup must stay disabled
|
||||
# in the repository settings: while it is enabled, code scanning rejects this workflow's uploads.
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
# Dependabot pull requests too: code scanning accepts uploads from pull_request runs despite their read-only token.
|
||||
pull_request:
|
||||
branches: [main]
|
||||
schedule:
|
||||
- cron: "17 3 * * 3"
|
||||
workflow_dispatch:
|
||||
|
||||
permissions: {}
|
||||
|
||||
concurrency:
|
||||
group: codeql-${{ github.event.pull_request.number || github.ref }}
|
||||
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
# Required checks of the main ruleset: keep the job names.
|
||||
name: Analyze (${{ matrix.language }})
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
permissions:
|
||||
contents: read
|
||||
security-events: write
|
||||
actions: read
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
language: [actions, csharp, python]
|
||||
steps:
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
# No build, for C# too: the extractor installs the SDK from global.json and restores the packages itself.
|
||||
- uses: github/codeql-action/init@9b3254085494b55a0f7c4c2b3d2d52cc712ce370 # v4.39.1
|
||||
with:
|
||||
languages: ${{ matrix.language }}
|
||||
build-mode: none
|
||||
|
||||
- uses: github/codeql-action/analyze@9b3254085494b55a0f7c4c2b3d2d52cc712ce370 # v4.39.1
|
||||
with:
|
||||
category: "/language:${{ matrix.language }}"
|
||||
@@ -31,6 +31,6 @@ jobs:
|
||||
results_format: sarif
|
||||
publish_results: true
|
||||
|
||||
- uses: github/codeql-action/upload-sarif@24c54180a607b1449ed407dd24f251e4e9147c8d # v4.38.3
|
||||
- uses: github/codeql-action/upload-sarif@9b3254085494b55a0f7c4c2b3d2d52cc712ce370 # v4.39.1
|
||||
with:
|
||||
sarif_file: results.sarif
|
||||
@@ -112,7 +112,7 @@ jobs:
|
||||
run: go run github.com/rhysd/actionlint/cmd/actionlint@v1.7.12 -color
|
||||
|
||||
- name: zizmor
|
||||
uses: zizmorcore/zizmor-action@85b2b9fb8e3325e7a23d7d0a9d7ba5ae0f999e3e # v0.7.1
|
||||
uses: zizmorcore/zizmor-action@53290badfa369cb0bf7ad16342cb62c2fa47ac7b # v0.8.0
|
||||
with:
|
||||
version: 1.31.1
|
||||
config: .github/zizmor.yml
|
||||
|
||||
@@ -2,6 +2,18 @@
|
||||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
## [1.2.2] - 2026-10-26
|
||||
|
||||
A security update: the app and the command-line tool now ship with the .NET 10.0.14 runtime.
|
||||
|
||||
### Security
|
||||
- Updated to the .NET 10.0.14 runtime (out-of-band security release with fixes for the Brotli decoder, CVE-2026-111497, and network sockets, CVE-2026-70197), which the self-contained downloads include.
|
||||
|
||||
### Changed
|
||||
- Updated Microsoft.Extensions and System.IO.Hashing to 10.0.14, System.CommandLine to 2.0.14, and the code analyzers and CI actions (CodeQL, zizmor) to their latest versions.
|
||||
|
||||
---
|
||||
|
||||
## [1.2.1] - 2026-10-25
|
||||
|
||||
A small maintenance release: two fixes found while adding several hundred tests, and code analysis on every change.
|
||||
|
||||
@@ -55,3 +55,6 @@ Run the app or smoke test with `HASHTOOL_DATA_DIR` pointing at a scratch folder
|
||||
- `sonarcloud.yml` — SonarCloud CI analysis (Automatic Analysis is off; project `poli0981_HashTool`): scanner build,
|
||||
Cobertura coverage from the tests and the smoke test (`dotnet-coverage`), "Sonar way" gate on new code. Skipped when
|
||||
`SONAR_TOKEN` isn't available (forks, Dependabot). Issues and hotspots can't be resolved from here; fix them in code.
|
||||
- `codeql.yml` — CodeQL advanced setup, mirroring default setup (actions, csharp, python; build mode none; default
|
||||
suite; `/language:` categories) but also analysing Dependabot pull requests. The `Analyze (…)` job names are required
|
||||
checks. Default setup must stay off: while it is on, it rejects uploads from workflows.
|
||||
+1
-1
@@ -14,7 +14,7 @@ Security problems: please **don't** open a public issue — see [SECURITY.md](SE
|
||||
|
||||
## Building and testing
|
||||
|
||||
You need the [.NET 10 SDK](https://dotnet.microsoft.com/download) (10.0.400 or newer) — `global.json` picks it up. Python 3 is only needed for the translation tool.
|
||||
You need the [.NET 10 SDK](https://dotnet.microsoft.com/download) (10.0.403 or newer) — `global.json` picks it up. Python 3 is only needed for the translation tool.
|
||||
|
||||
```text
|
||||
dotnet build HashTool.slnx -warnaserror # what CI runs; warnings are errors
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
|
||||
<!-- Single source of truth for the product version (the release workflow also passes -p:Version=<tag>). -->
|
||||
<Version>1.2.1</Version>
|
||||
<Version>1.2.2</Version>
|
||||
<Authors>poli0981</Authors>
|
||||
<Company>poli0981</Company>
|
||||
<Product>Hash Tool</Product>
|
||||
|
||||
@@ -17,11 +17,11 @@
|
||||
<ItemGroup Label="Application">
|
||||
<PackageVersion Include="Blake3" Version="3.0.2" />
|
||||
<PackageVersion Include="CommunityToolkit.Mvvm" Version="8.4.2" />
|
||||
<PackageVersion Include="System.CommandLine" Version="2.0.13" />
|
||||
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="10.0.13" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Logging" Version="10.0.13" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="10.0.13" />
|
||||
<PackageVersion Include="System.IO.Hashing" Version="10.0.13" />
|
||||
<PackageVersion Include="System.CommandLine" Version="2.0.14" />
|
||||
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="10.0.14" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Logging" Version="10.0.14" />
|
||||
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="10.0.14" />
|
||||
<PackageVersion Include="System.IO.Hashing" Version="10.0.14" />
|
||||
<PackageVersion Include="Velopack" Version="1.2.161" />
|
||||
</ItemGroup>
|
||||
|
||||
@@ -30,8 +30,8 @@
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Label="Analyzers">
|
||||
<PackageVersion Include="Meziantou.Analyzer" Version="3.0.303" />
|
||||
<PackageVersion Include="ReferenceTrimmer" Version="3.5.9" />
|
||||
<PackageVersion Include="Meziantou.Analyzer" Version="3.0.317" />
|
||||
<PackageVersion Include="ReferenceTrimmer" Version="3.5.13" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Label="Tests">
|
||||
|
||||
@@ -103,7 +103,7 @@ gh attestation verify HashTool-win-Setup.exe --repo poli0981/HashTool
|
||||
|
||||
## Building from source
|
||||
|
||||
Requires the [.NET 10 SDK](https://dotnet.microsoft.com/download) (10.0.400 or newer).
|
||||
Requires the [.NET 10 SDK](https://dotnet.microsoft.com/download) (10.0.403 or newer).
|
||||
|
||||
```text
|
||||
dotnet build HashTool.slnx
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"sdk": {
|
||||
"version": "10.0.400",
|
||||
"version": "10.0.403",
|
||||
"rollForward": "latestFeature",
|
||||
"allowPrerelease": false
|
||||
},
|
||||
|
||||
@@ -18,8 +18,9 @@ namespace HashTool.App.Infrastructure;
|
||||
|
||||
/// <summary>
|
||||
/// <c>CheckHash --smoke-test [--smoke-out result.json] [--expect-version 1.2.0]</c>: starts the app headless, loads every
|
||||
/// page and language, hashes and verifies a file, and reports the Velopack install state. Used by CI and the release
|
||||
/// upgrade gate on published (single-file) builds.
|
||||
/// page and language, hashes and verifies a file, and reports the Velopack install state and the .NET runtime it runs on
|
||||
/// (the one bundled into self-contained releases). Used by CI and the release upgrade gate on published (single-file)
|
||||
/// builds.
|
||||
/// </summary>
|
||||
public static class SmokeTest
|
||||
{
|
||||
@@ -131,6 +132,7 @@ public static class SmokeTest
|
||||
public int Languages { get; set; }
|
||||
public string? DataDirectory { get; set; }
|
||||
public string Culture { get; set; } = CultureInfo.CurrentUICulture.Name;
|
||||
public string Runtime { get; set; } = Environment.Version.ToString();
|
||||
public List<string> Errors { get; } = [];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Text.Json;
|
||||
using HashTool.App.Infrastructure;
|
||||
using HashTool.App.Infrastructure.Logging;
|
||||
using HashTool.App.ViewModels;
|
||||
@@ -74,6 +75,20 @@ public sealed class AppCommandLineTests
|
||||
}
|
||||
}
|
||||
|
||||
public sealed class SmokeReportTests
|
||||
{
|
||||
[Fact]
|
||||
public void Json_NamesTheRuntimeTheAppRunsOn()
|
||||
{
|
||||
// Release logs show this value to prove which .NET runtime a self-contained build bundles.
|
||||
using var json = JsonDocument.Parse(JsonSerializer.Serialize(new SmokeTest.SmokeReport(), SmokeJsonContext.Default.SmokeReport));
|
||||
|
||||
Assert.Equal(Environment.Version.ToString(), json.RootElement.GetProperty("runtime").GetString());
|
||||
Assert.False(json.RootElement.GetProperty("ok").GetBoolean());
|
||||
Assert.Equal(0, json.RootElement.GetProperty("errors").GetArrayLength());
|
||||
}
|
||||
}
|
||||
|
||||
public sealed class TextHelperTests
|
||||
{
|
||||
[Fact]
|
||||
|
||||
Reference in new issue
Block a user