# AWS - DataPipeline, CodePipeline & CodeCommit Enum {{#include ../../../banners/hacktricks-training.md}} ## DataPipeline AWS Data Pipelineは、データの**アクセス、変換、および効率的な転送**を大規模に促進するように設計されています。以下の操作を実行できます: 1. **データが保存されている場所にアクセス**: 様々なAWSサービスに保存されているデータにシームレスにアクセスできます。 2. **スケールでの変換と処理**: 大規模なデータ処理と変換タスクが効率的に処理されます。 3. **結果を効率的に転送**: 処理されたデータは、以下の複数のAWSサービスに効率的に転送できます: - Amazon S3 - Amazon RDS - Amazon DynamoDB - Amazon EMR 本質的に、AWS Data Pipelineは、指定された間隔で異なるAWSコンピューティングおよびストレージサービス、ならびにオンプレミスのデータソース間でのデータの移動と処理を合理化します。 ### Enumeration ```bash aws datapipeline list-pipelines aws datapipeline describe-pipelines --pipeline-ids aws datapipeline list-runs --pipeline-id aws datapipeline get-pipeline-definition --pipeline-id ``` ### プライベートエスカレーション 次のページでは、**データパイプラインの権限を悪用して特権を昇格させる方法**を確認できます: {{#ref}} ../aws-privilege-escalation/aws-datapipeline-privesc/README.md {{#endref}} ## コードパイプライン AWS CodePipelineは、**継続的デリバリーサービス**を完全に管理するもので、**リリースパイプラインを自動化**して、迅速かつ信頼性の高いアプリケーションおよびインフラストラクチャの更新を支援します。 CodePipelineは、リリースモデルに基づいて、コード変更があるたびにリリースプロセスの**ビルド、テスト、デプロイフェーズ**を自動化します。 ### 列挙 ```bash aws codepipeline list-pipelines aws codepipeline get-pipeline --name aws codepipeline list-action-executions --pipeline-name aws codepipeline list-pipeline-executions --pipeline-name aws codepipeline list-webhooks aws codepipeline get-pipeline-state --name ``` ### Privesc 次のページでは、**codepipelineの権限を悪用して特権を昇格させる方法**を確認できます: {{#ref}} ../aws-privilege-escalation/aws-codepipeline-privesc/README.md {{#endref}} ## CodeCommit これは、Amazonによってホストされ完全に管理されている**バージョン管理サービス**であり、データ(文書、バイナリファイル、ソースコード)をプライベートに保存し、クラウドで管理するために使用できます。 これにより、ユーザーがGitを知っている必要がなく、**自分のソース管理システムを管理する**ことや、インフラをスケールアップまたはダウンすることを心配する必要がなくなります。Codecommitは、Gitに見られるすべての標準的な**機能**をサポートしており、ユーザーの現在のGitベースのツールと問題なく連携します。 ### Enumeration ```bash # Repos aws codecommit list-repositories aws codecommit get-repository --repository-name aws codecommit get-repository-triggers --repository-name aws codecommit list-branches --repository-name aws codecommit list-pull-requests --repository-name # Approval rules aws codecommit list-approval-rule-templates aws codecommit get-approval-rule-template --approval-rule-template-name aws codecommit list-associated-approval-rule-templates-for-repository --repository-name # Get & Put files ## Get a file aws codecommit get-file --repository-name backend-api --file-path app.py ## Put a file aws codecommit get-branch --repository-name backend-api --branch-name master aws codecommit put-file --repository-name backend-api --branch-name master --file-content fileb://./app.py --file-path app.py --parent-commit-id # SSH Keys & Clone repo ## Get codecommit keys aws iam list-ssh-public-keys #User keys for CodeCommit aws iam get-ssh-public-key --user-name --ssh-public-key-id --encoding SSH #Get public key with metadata # The previous command will give you the fingerprint of the ssh key # With the next command you can check the fingerprint of an ssh key and compare them ssh-keygen -f .ssh/id_rsa -l -E md5 # Clone repo git clone ssh://@git-codecommit..amazonaws.com/v1/repos/ ``` ## 参考文献 - [https://docs.aws.amazon.com/whitepapers/latest/aws-overview/analytics.html](https://docs.aws.amazon.com/whitepapers/latest/aws-overview/analytics.html) {{#include ../../../banners/hacktricks-training.md}}