installer v1 (A+B): install-code enrollment, panel code UI, EXE publish; DPAPI credential store
This commit is contained in:
@@ -412,6 +412,14 @@ class AgentEnrollment(Base):
|
||||
enrollment_token_hash: Mapped[str | None] = mapped_column(String(64), nullable=True)
|
||||
enrollment_token_expires_at: Mapped[datetime | None] = mapped_column(DateTime(timezone=True), nullable=True)
|
||||
enrollment_used_at: Mapped[datetime | None] = mapped_column(DateTime(timezone=True), nullable=True)
|
||||
# The install code typed by the operator into the universal EXE installer.
|
||||
# Only its SHA-256 is stored (normalize → digest), never the plaintext.
|
||||
# A new code (rotation) rewrites these three fields; the previous code
|
||||
# becomes unusable the moment a new one is generated.
|
||||
install_code_hash: Mapped[str | None] = mapped_column(String(64), nullable=True)
|
||||
install_code_expires_at: Mapped[datetime | None] = mapped_column(DateTime(timezone=True), nullable=True)
|
||||
install_code_attempts: Mapped[int] = mapped_column(Integer, default=0, server_default="0")
|
||||
install_code_created_at: Mapped[datetime | None] = mapped_column(DateTime(timezone=True), nullable=True)
|
||||
machine_fingerprint_seen: Mapped[str | None] = mapped_column(String(128), nullable=True)
|
||||
hostname_seen: Mapped[str | None] = mapped_column(String(255), nullable=True)
|
||||
hostname_mismatch: Mapped[bool] = mapped_column(Boolean, default=False, server_default="false")
|
||||
|
||||
Reference in New Issue
Block a user