diff --git a/lib/std/crypto.zig b/lib/std/crypto.zig index d15ec2cff2..9fbe70f815 100644 --- a/lib/std/crypto.zig +++ b/lib/std/crypto.zig @@ -63,8 +63,8 @@ test "crypto" { _ = @import("crypto/25519/curve25519.zig"); _ = @import("crypto/25519/ed25519.zig"); _ = @import("crypto/25519/edwards25519.zig"); - _ = @import("crypto/25519/field25519.zig"); - _ = @import("crypto/25519/scalar25519.zig"); + _ = @import("crypto/25519/field.zig"); + _ = @import("crypto/25519/scalar.zig"); _ = @import("crypto/25519/x25519.zig"); _ = @import("crypto/25519/ristretto255.zig"); } diff --git a/lib/std/crypto/25519/curve25519.zig b/lib/std/crypto/25519/curve25519.zig index 011c926f64..4fb569ccfb 100644 --- a/lib/std/crypto/25519/curve25519.zig +++ b/lib/std/crypto/25519/curve25519.zig @@ -3,9 +3,9 @@ const std = @import("std"); /// Group operations over Curve25519. pub const Curve25519 = struct { /// The underlying prime field. - pub const Fe = @import("field25519.zig").Fe; + pub const Fe = @import("field.zig").Fe; /// Field arithmetic mod the order of the main subgroup. - pub const scalar = @import("scalar25519.zig"); + pub const scalar = @import("scalar.zig"); x: Fe, diff --git a/lib/std/crypto/25519/edwards25519.zig b/lib/std/crypto/25519/edwards25519.zig index c28ed6865d..3d21af40e5 100644 --- a/lib/std/crypto/25519/edwards25519.zig +++ b/lib/std/crypto/25519/edwards25519.zig @@ -4,9 +4,9 @@ const fmt = std.fmt; /// Group operations over Edwards25519. pub const Edwards25519 = struct { /// The underlying prime field. - pub const Fe = @import("field25519.zig").Fe; + pub const Fe = @import("field.zig").Fe; /// Field arithmetic mod the order of the main subgroup. - pub const scalar = @import("scalar25519.zig"); + pub const scalar = @import("scalar.zig"); x: Fe, y: Fe, diff --git a/lib/std/crypto/25519/field25519.zig b/lib/std/crypto/25519/field.zig similarity index 100% rename from lib/std/crypto/25519/field25519.zig rename to lib/std/crypto/25519/field.zig diff --git a/lib/std/crypto/25519/scalar25519.zig b/lib/std/crypto/25519/scalar.zig similarity index 99% rename from lib/std/crypto/25519/scalar25519.zig rename to lib/std/crypto/25519/scalar.zig index a94e6531dc..6971b43489 100644 --- a/lib/std/crypto/25519/scalar25519.zig +++ b/lib/std/crypto/25519/scalar.zig @@ -174,7 +174,7 @@ test "non-canonical scalar25519" { std.testing.expectError(error.NonCanonical, rejectNonCanonical(too_targe)); } -test "mulAdd overflow check" { +test "scalar25519 mulAdd overflow check" { const a: [32]u8 = [_]u8{0xff} ** 32; const b: [32]u8 = [_]u8{0xff} ** 32; const c: [32]u8 = [_]u8{0xff} ** 32;