Urgent.News

What's breaking now, across hundreds of outlets.

Tech

The Fix for Leaked Keys Isn't on Your Laptop. It's in the Repo

I made a new folder on my laptop, typed git init , and dropped a file into .claude/ with a made-up key in it. Then I ran the three commands every one of us runs without thinking: git status , git add . , git commit . Nothing stopped me at any step. The file went in like any other file, and the commit took it without a word. That is the whole story of the Claude Code secrets leak, and it is less…

A new folder was created on a laptop and a file with a fake key was added to it. Three common commands were then executed without any issues: git status, git add ., and git commit. The file was added to the repository without any warnings or prompts, appearing as untracked and getting committed in the same way regular files are.

This process was repeated in the reporter's usual setup, and the file was not detected or added to the repository. The reason for this difference is that a global ignore rule, which prevents certain files from being added to the repository, was set up on the reporter's machine but not on the other machine. This illustrates how the protection against the leak is not consistent across different machines, and it is not embedded within the repository itself.

The issue is not with the Git tool itself, but with the lack of rules and safeguards applied to the project as a whole. A simple fix could involve adding the folder containing the keys to the repository's own .gitignore file, ensuring the rule travels with the project and applies to all machines. Additionally, it is important to review git status before committing any new files and maintain the use of a global ignore rule, even though its effectiveness is limited without project-wide implementation.

Lastly, if a key ever manages to be committed, it should be rotated immediately to minimize the potential damage.

Rewritten by urgent.news; may contain errors — check the original.

Source: dev.to

Read the original at dev.to →

Report a problem with this story

More in Tech

How we plan a platform before writing the first line of code

Most projects that go wrong do not fail in the code. They fail in a meeting months earlier, when everyone nodded at a sentence that meant something different to each person.

  • Establish a concise goal sentence for the platform
  • Identify key users and their needs, devices, and interaction frequency
  • Draft a scope document detailing included and excluded features

AWS Lambda Doubles Its Timeout to 30 Minutes After Eight Years at 15

AWS has raised the maximum timeout of on-demand Lambda Event Functions from 15 to 30 minutes in all commercial regions, with no opt-in and no new pricing. The limit had stood since 2018.

  • AWS Lambda doubles its maximum execution time from 15 to 30 minutes.
  • Change effective since August 2017, impacting synchronous and asynchronous invocations.
  • Longer tasks advised to use AWS Step Functions for better manageability.

More from Wednesday 25 November →