429 karma · joined Oct 12, 2013 (13y ago) · 212 submissions
comment 7mo ago · link · parent
Filter for `HasEverRun=true`; if it's not run, the secrets can't have been exposed.
Review the URL; this says who you're calling. Purists would say that if you've called any endpoints there's a risk. However for most companies I'd say you can trust services provided by folk like Microsoft (they host GitHub anyway) and Snyk (if you're relying on them for security scanning, you should be able to trust them), so if you see webhooks to Azure DevOps (dev.azure.com) or to Snyk (api.snyk.io) you can assume that anything exposed there isn't a concern. You don't need to worry about proxys on egress - since this is GitHub Cloud, so calls egress from GitHub rather than through your own network. So the only concerns would be in house or third party developed endpoints where you feel those companies (/their employees who have access to their ingress logs) may be a risk.
comment 7mo ago · link · parent
# Authenticate via `gh auth login -s admin:enterprise` before running this script
# Save this script as c:\\temp\GHWebookAudit.ps1; then navigate to c:\\temp\ and invoke via `.\GHWebookAudit.ps1 -Orgs @("MyExampleOrg", "MyOtherExampleOrg") -InformationAction Continue`
[CmdletBinding()]
Param (
[Parameter(Mandatory)]
[string[]]$Orgs
)
$results = foreach ($org in $Orgs) {
Write-Information "Fetching ALL repositories for org [$org]..."
# gh api --paginate fetches every page and outputs a stream of JSON arrays
# We use -Raw to ensure we capture the full stream before converting
$reposJson = gh api --paginate "orgs/$org/repos?per_page=1000"
# ConvertFrom-Json can handle multiple JSON arrays in the stream
$repos = $reposJson | ConvertFrom-Json
# Sometimes the pagination returns a single array or a list of arrays;
# Ensure we are iterating over the objects themselves.
$repoList = if ($repos.GetType().IsArray -and $repos[0].GetType().IsArray) {
$repos | ForEach-Object { $_ }
} else {
$repos
}
Write-Information "Found $($repoList.Count) repositories. Starting audit..."
foreach ($repoObj in $repoList) {
$repoName = $repoObj.name
$fullRepo = "$org/$repoName"
Write-Information "Checking: $fullRepo"
# Get all hooks for the repository
$hooksJson = gh api "repos/$fullRepo/hooks" 2>$null
if (-not $hooksJson) { continue }
$hooks = $hooksJson | ConvertFrom-Json
foreach ($hook in $hooks) {
$hookId = $hook.id
$hookUrl = $hook.config.url
# Get the most recent delivery... we could pontentially check for activity between the impacted dates, but that would need additional filters/commplexity; for now keeping it relatively simple
# correction: this only goes back 3 days; so doesn't work... https://docs.github.com/en/webhooks/testing-and-troubleshooting-webhooks/viewing-webhook-deliveries
# # $deliveriesJson = gh api "repos/$fullRepo/hooks/$hookId/deliveries" --limit 1 2>$null
# instead use th eexisting hook response's last response status just to say if it has run; though that doesn't say when
# Extract last response details
$lastStatus = $hook.last_response.status
$lastCode = $hook.last_response.code
$hasEverRun = ($lastStatus -eq 'active') # active vs unused
[PSCustomObject]@{
Organization = $org
Repository = $repoName
HookID = $hookId
Active = $hook.active
URL = $hookUrl
HasEverRun = $hasEverRun
LastStatus = $lastStatus
LastHTTPCode = $lastCode
UpdatedAt = $hook.updated_at
}
}
}
}
# Final Output
if ($results.Count) {
$results | Export-Csv -Path "./Full_Webhook_Audit_Report.csv" -NoTypeInformation
Write-Information "Audit complete! $($results.Count) hooks found. Results saved to Full_Webhook_Audit_Report.csv"
} else {
Write-Information "No webhooks found across the organizations."
}comment 7mo ago · link · parent
Checking the listed impacted web hooks I noticed that no repo's listed twice, even though some have multiple hooks defined... That makes me think the report may have a bug.
Also, many of the listed hooks show as `This hook has never been triggered`; which if correct means it wouldn't have had an issue as the compromised payload's never been sent to it.
I'll write a powershell script (well, AI will write it and then I'll tweak) to help check which webhooks have been called in this time window (or at least, say they were most recently triggered after the issue first began) to help get a more accurate report of what's concerning. If that proves useful, I'll share here.
comment 3y ago · link · parent
- Plot
- World Building
- Character
- etc (There's a specific list mentioned, but I can't recall it)
That's the simpler classification side of things, so easier to code up... Your example of the canoe trip would be significanlty more complex; but definitely more a scenario worthy of AI over basic heuristics... and something that would need a conversation to drill down into (i.e. did the story evoke the scenery of their trip, or was it reflecting the relationship between the people, etc).comment 3y ago · link · parent
It's apparant that it wasn't without issues prior to acquisition (e.g. a quick search for GitHub issues prior to 2018 gives this: https://techcrunch.com/2017/07/31/github-goes-down-and-takes...) - reporting issues in 2017, 2015, and 2012.
I don't have the data to comment on whether it was better before or after MS acquisition, but would suggest this isn't the best sample size to base any conclusions on.
comment 4y ago · link · parent
comment 4y ago · link · parent
Error message
Android Recovery
Fairphone/FP3/FP3
11/8901.4.A.0017.3/gms-15368f27
user/release-keys
Use volume up/down and power.
Cannot load Android system. Your data may be corrupt. If
you continue to get this message, you may need to perform
a factory data reset and erase all user data stored on this
device.
Try agian
Factory data reset
I thought sharing here may aid discovery / if we can collect data from those hitting this issue maybe we can more easily identify the underlying cause.9.
Android Recovery / FairPhone 3(forum.fairphone.com ↗)
2 points · by johnlbevan2 · 4y ago · 2 comments
comment 5y ago · link · parent
Lots more under this link: https://stackoverflow.com/questions?thekey
comment 5y ago · link · parent
comment 6y ago · link · parent
comment 6y ago · link · parent
comment 6y ago · link · parent
"Race condition" is just as offensive as "Master Branch" - neither are relating to prejudice / historic injustice; but use different meanings of these potentially loaded words.
That said, nothing against switching to non-loaded terms; especially if the effort to do so is less than the effort to debate it. But we mustn't accuse people of being racist just because they're using terminology that some are offended by when those using the terminology are simply using terminology they've learnt, and could have no reasonable expectation to have considered that it may be deemed offsensive.
comment 6y ago · link · parent
"Do you work from home more than 50% of your working hours?" has a simple yes/no answer. "What is your salary, including average annual bonus, after tax?" has a single numeric answer.
"How many years have you been a developer?" sounds simple; but has interpretation issues. Do I count from my first line of code when playing as a kid, my first computer science class, my first paying job as a developer, or some other time? If this is a measure of seniority (e.g. we define senior as anyone who's been coding for 10+ years) there will be a mixed bag.
This may mean that despite trying to factor out variables they're hiding in the noise of bad data; so may still have a hand in the result. i.e. Those developers who've counted 9 years developing from their first salaried job and now earn more and work from home are in the same group as those who've just graduated but counted their time coding from their 8-year-old-self's first foray who are in their first year of the job, and thus on lower salary and less perks.
comment 6y ago · link · parent
comment 7y ago · link · parent
comment 7y ago · link · parent
When using a new ingredient, try it in something you're already familiar with, so you can isolate that ingredient, rather than introducing it in a completely new recipe where you can't easily tell what impact that ingredient has vs others in the recipe.
Think about how to setup your kitchen - is it better to have all your spice containers in a group with one another, where they all look similar, or to put them alongside the items you use them with (tumeric with your basmati rice, nutmeg with your pestle & mortar, etc) so that it's easier to find everything you need for a recipe.
comment 7y ago · link · parent
Think of all the times you've seen poorly worded questions on Stack Overflow, in support tickets, etc. Think of the power that being able to get answers to your questions has.
Most of us are good at asking questions where we're working within our comfort zones, but struggle when we're on unfamiliar territory (e.g. I'll ask a better question if I have some issue with my code than I would if I were talking to a mechanic about a problem with my car, since I don't know the terminology / worry more about appearing ignorant in the latter scenario). However, by taking time to consider what's useful to the mechanic & what I can report as fact vs my opinion, I can ask a cleaner question.
Related, it's also good to learn how to think about things as a collection of dependencies, and how to debug/analyse issues by testing different parts of that dependency graph to isolate variables and narrow down where in that graph an issue must exist. This both helps to ask cleaner questions, provide more background information, and often to resolve issues for yourself.