CARVIEW |
Select Language
HTTP/2 200
date: Sun, 27 Jul 2025 23:18:49 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
x-repository-download: git clone https://github.com/git/git.git
etag: W/"b885ccd5db0ee34279d65ee2e7034c15"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: no-referrer-when-downgrade
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=tU8iSEPN%2BrG398iXT5yuihbDaomD2KfPzLC5rXNt%2BJ9Lx8pbvqxTPro%2BnTFAvUfAwmfshb4hSmuyZ%2ByUngfi68DD0K13HMTxpQ4oznV0t8XHOjPjlpCKwdbrE1G%2FOYoS8Nfsq5Hh7ygEJ95tzmfR%2BQlYId3r1YvwGwCb3Umksq4fwJdIIvnqWcnfsP20PKlNpnET9xvEO0dNLbM6Q9umo4afDTybGACgd7PwoqbVUFFExRd8vbKHzb2rfDy6IXPzeC9%2BV76Ybq4JMJHOq13Fdw%3D%3D--1gkfnDd%2BEK5kG%2FQP--usPmVt5%2BKEhfwKv8rMtLPQ%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.1743675153.1753658328; Path=/; Domain=github.com; Expires=Mon, 27 Jul 2026 23:18:48 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Mon, 27 Jul 2026 23:18:48 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: 8872:1AFF47:1216D87:17DEC18:6886B3D8
git-prompt.sh: don't put unsanitized branch names in $PS1 · git/git@8976500 · GitHub
Copy file name to clipboardExpand all lines: contrib/completion/git-prompt.sh
Skip to content
Navigation Menu
{{ message }}
-
Notifications
You must be signed in to change notification settings - Fork 26.4k
Commit 8976500
git-prompt.sh: don't put unsanitized branch names in $PS1
Both bash and zsh subject the value of PS1 to parameter expansion,
command substitution, and arithmetic expansion. Rather than include
the raw, unescaped branch name in PS1 when running in two- or
three-argument mode, construct PS1 to reference a variable that holds
the branch name. Because the shells do not recursively expand, this
avoids arbitrary code execution by specially-crafted branch names such
as '$(IFS=_;cmd=sudo_rm_-rf_/;$cmd)'.
Signed-off-by: Richard Hansen <rhansen@bbn.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>1 parent 7bbc4e8 commit 8976500Copy full SHA for 8976500
File tree
Expand file treeCollapse file tree
2 files changed
+54
-24
lines changedFilter options
- contrib/completion
- t
Expand file treeCollapse file tree
2 files changed
+54
-24
lines changedcontrib/completion/git-prompt.sh
Copy file name to clipboardExpand all lines: contrib/completion/git-prompt.sh+32-2Lines changed: 32 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
207 | 207 |
| |
208 | 208 |
| |
209 | 209 |
| |
210 |
| - | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
211 | 222 |
| |
212 | 223 |
| |
213 | 224 |
| |
| |||
438 | 449 |
| |
439 | 450 |
| |
440 | 451 |
| |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
441 | 471 |
| |
442 |
| - | |
| 472 | + | |
443 | 473 |
| |
444 | 474 |
| |
445 | 475 |
| |
|
+22-22Lines changed: 22 additions & 22 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
452 | 452 |
| |
453 | 453 |
| |
454 | 454 |
| |
455 |
| - | |
| 455 | + | |
456 | 456 |
| |
457 | 457 |
| |
458 | 458 |
| |
459 | 459 |
| |
460 |
| - | |
| 460 | + | |
461 | 461 |
| |
462 | 462 |
| |
463 | 463 |
| |
464 | 464 |
| |
465 | 465 |
| |
466 |
| - | |
| 466 | + | |
467 | 467 |
| |
468 | 468 |
| |
469 | 469 |
| |
470 |
| - | |
| 470 | + | |
471 | 471 |
| |
472 | 472 |
| |
473 | 473 |
| |
474 | 474 |
| |
475 | 475 |
| |
476 |
| - | |
| 476 | + | |
477 | 477 |
| |
478 | 478 |
| |
479 | 479 |
| |
480 | 480 |
| |
481 | 481 |
| |
482 |
| - | |
| 482 | + | |
483 | 483 |
| |
484 | 484 |
| |
485 | 485 |
| |
486 | 486 |
| |
487 | 487 |
| |
488 |
| - | |
| 488 | + | |
489 | 489 |
| |
490 | 490 |
| |
491 | 491 |
| |
492 | 492 |
| |
493 | 493 |
| |
494 | 494 |
| |
495 |
| - | |
| 495 | + | |
496 | 496 |
| |
497 | 497 |
| |
498 | 498 |
| |
499 | 499 |
| |
500 | 500 |
| |
501 |
| - | |
| 501 | + | |
502 | 502 |
| |
503 | 503 |
| |
504 | 504 |
| |
505 | 505 |
| |
506 | 506 |
| |
507 | 507 |
| |
508 | 508 |
| |
509 |
| - | |
| 509 | + | |
510 | 510 |
| |
511 | 511 |
| |
512 | 512 |
| |
513 | 513 |
| |
514 | 514 |
| |
515 |
| - | |
| 515 | + | |
516 | 516 |
| |
517 | 517 |
| |
518 | 518 |
| |
| |||
521 | 521 |
| |
522 | 522 |
| |
523 | 523 |
| |
524 |
| - | |
| 524 | + | |
525 | 525 |
| |
526 | 526 |
| |
527 | 527 |
| |
528 | 528 |
| |
529 | 529 |
| |
530 |
| - | |
| 530 | + | |
531 | 531 |
| |
532 | 532 |
| |
533 | 533 |
| |
534 | 534 |
| |
535 | 535 |
| |
536 |
| - | |
| 536 | + | |
537 | 537 |
| |
538 | 538 |
| |
539 | 539 |
| |
540 | 540 |
| |
541 | 541 |
| |
542 |
| - | |
| 542 | + | |
543 | 543 |
| |
544 | 544 |
| |
545 | 545 |
| |
546 | 546 |
| |
547 | 547 |
| |
548 | 548 |
| |
549 | 549 |
| |
550 |
| - | |
| 550 | + | |
551 | 551 |
| |
552 | 552 |
| |
553 | 553 |
| |
554 | 554 |
| |
555 | 555 |
| |
556 |
| - | |
| 556 | + | |
557 | 557 |
| |
558 | 558 |
| |
559 | 559 |
| |
560 | 560 |
| |
561 | 561 |
| |
562 | 562 |
| |
563 | 563 |
| |
564 |
| - | |
| 564 | + | |
565 | 565 |
| |
566 | 566 |
| |
567 | 567 |
| |
568 | 568 |
| |
569 | 569 |
| |
570 |
| - | |
| 570 | + | |
571 | 571 |
| |
572 | 572 |
| |
573 | 573 |
| |
574 | 574 |
| |
575 |
| - | |
| 575 | + | |
576 | 576 |
| |
577 | 577 |
| |
578 | 578 |
| |
579 | 579 |
| |
580 | 580 |
| |
581 |
| - | |
| 581 | + | |
582 | 582 |
| |
583 | 583 |
| |
584 | 584 |
| |
585 | 585 |
| |
586 |
| - | |
| 586 | + | |
587 | 587 |
| |
588 | 588 |
| |
589 | 589 |
| |
|
You can’t perform that action at this time.
0 commit comments