Quantcast
Channel: 空想ブログ
Browsing all 167 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

Terraform でGCP の WAF である Cloud Armor を構築、SQLi をブロック

概要 やりたいこと Web サイトへの SQL Injection や XSS などの攻撃をブロックしたい。 GCP は WAF サービスとして Cloud Armor を提供しているため、これを利用する。 Cloud Armor は LB に紐付けるため、前回構築した環境を流用する。 Terraform で GCE + LB を構築、 Apache へアクセス Cloud Armor とは...

View Article


Image may be NSFW.
Clik here to view.

Terraform で GCP Cloud Armor ログを有効化、 Logging でログを検索

概要 やりたいこと Cloud Armor ログを確認したい。 全体像 Cloud Armor 用のログが存在するわけでなく、LB のログの一環として出力される。 WAF ログを出すためには LB のログを出すLBのログはバックエンドサービスで出す Cloud Armor ログ (LB ログ) ログ情報は LB のロギングページで確認できる。 HTTP(S) 負荷分散のロギングとモニタリング...

View Article


Image may be NSFW.
Clik here to view.

GCP Cloud Armor ログ(LBログ)を Logging から BigQuery へエクスポート

概要 やりたいこと BigQuery で Cloud Armor ログを検索したい。 Logging から BigQeury へ Cloud Armor ログ (LB ログ) をエクスポートできる。 Terraform で GCP Cloud Armor ログを有効化、 Logging でログを検索 ログルーターのシンク Logging からログをエクスポートするのに、ログルーターのシンクがある。...

View Article

Image may be NSFW.
Clik here to view.

Cloud Armor ログを BigQuery で検索する

概要 やりたいこと Cloud Armor ログを BigQuery で検索する。 前回 GCP Cloud Armor ログ(LBログ)を Logging から BigQuery へエクスポート パーティション分割テーブル パーティション分割テーブルは、パーティションと呼ばれるセグメントにテーブルを分割することで、クエリのパフォーマンスを向上させる。BigQuery...

View Article

GCP Security Command Center 何ができるか

概要 やりたいこと GCP の Security Command Center (以下 SCC) で何ができるか知りたい。 ざっくり GCP のセキュリティサービスを確認したところ、 SCC に集約されているようだ。 WIP : GCP セキュリティサービス Security Command Center SCC は GCP...

View Article


Image may be NSFW.
Clik here to view.

Terraform で GCP Security Command Center のアラートを Slack 通知

概要 やりたいこと Security Command Center のアラートを Slack 通知したい。 Cloud Pub/Sub + CloudFunctions で Slack 通知の仕方は以下。 Terraform で GCP のアラートを Slack 通知する Security Command Center については以下。 GCP Security Command Center...

View Article

Image may be NSFW.
Clik here to view.

Terraform で Slack Evetns API + API Gateway + Lambda な slackbot を構築

概要 やりたいこと Slack Events API の Challenge 認証する API Gateway + Lambda を Terraform で作成したい。 API Gateway API Gateway に関しては下記が大変わかりやすい。 Amazon API Gateway は何をしてるのか 下記記事から API Gateway 作成パターンを引用。 今度こそ (REST) API...

View Article

Image may be NSFW.
Clik here to view.

Alexa カスタムスキルを Terraform + Lambda + Python で作成する

概要 Alexa カスタムスキル Alexa のアプリケーションロジックを、開発者が AWS などでバックエンドサービスとして構築したもの。 Alexa Skills Kit が提供されている言語は 3つ。 Node.jsJavaPython Alexa カスタムスキル作成 「ハロー」と呼んだら「ハローパイソン!」と返すスキルを作成する。 Amazon Developer アカウント作成...

View Article


Image may be NSFW.
Clik here to view.

APL (Alexa Presentation Language) で Hello World

概要 APL とは Alexa Presentation Language(APL)を使用すると、ディスプレイを利用したスキルを作成できる。 Echo Show や Fire タブレットなどのディスプレイが付いた機器で利用を想定するスキルとなる。 ディスプレイを利用したスキルを、マルチモーダルスキルと呼ぶ。 APL 書き方 APL の実態は Json 。ほぼ CSS と同じイメーで書ける。 この...

View Article


Image may be NSFW.
Clik here to view.

APL (Alexa Presentation Language) カスタムスキルで Hello World

概要 前回、 hosted skills を利用して APL で Hello World を表示した。 APL (Alexa Presentation Language) で Hello World 今回はチュートリアルとして、これを Terraform でカスタムスキルとして作成する。 APL カスタムスキル作成 APL 用プロジェクト作成 以下でプロジェクト作成し、Skill builder...

View Article

Image may be NSFW.
Clik here to view.

Flutter + Riverpod 1.0.3 で Hello World 苦戦した

環境構築に苦戦した。 VSCode からプロジェクトを作るとエラーに遭遇、CLI からプロジェクトを作成した。 概要 Riverpod のチュートリアルをやる。 Getting started 環境 Flutter v2.8.1riverpod v1.0.3flutter_riverpod v1.0.3 実践 CLI Flutter プロジェクト作成 flutter create...

View Article

Image may be NSFW.
Clik here to view.

【WIP】Flutter speech_to_text 5.4.2 が iOS シミュレータ上で音認識してくれない

一人で PC に向かってハロー・ハロー言い続けてる。 概要 公式の example 通りにやってるが、声を受け付けてくれない。 speech_to_text 環境 Mac Big Surに構築。 $ flutter doctor Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel...

View Article

Flutter で Widget, Class, ファイルを分割するチュートリアル

概要 やりたいこと flutter create 時に作成されるカウンターアプリを Class と Widget 分けていきます。 下記を参考にさせていただきました。追加で NullSafety などを対応していく。 Flutterに入門して疑問に思ったことと、そのとき調べたこと Flutter 初期アプリ自体の解説はこのブログが神。 Flutter はじめの一歩 環境 Mac Big...

View Article


Image may be NSFW.
Clik here to view.

GCE にアクセスできない時、カーネルパニックが起きていたので対処

概要 GCP の GCE インスタンスにアクセスできなくなった。 環境 GCE e2-smallCentOS7 現象 コンソールからも ssh アクセスできない コンソールから ssh アクセスできない。 コンソール上ではインスタンは起動している状態。 停止→開始を行っても変化なし。 シリアルコンソールを確認 こういうときはシリアルコンソールを確認する。 確認手順 対象インスンタンスを選択...

View Article

[Flutter] Android Studio の JDK を指定する [Mac]

概要 flutter doctor で警告が発生。 $ flutter doctor Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 2.8.1, on macOS 11.4 20F71 darwin-x64, locale ja-JP) [!] Android...

View Article


Image may be NSFW.
Clik here to view.

Flutter go_router 公式サンプルを動かすチュートリアル

概要 go_router の公式サンプルを動かす。 go_router | Flutter PackageA declarative router for Flutter based on Navigation 2 supporting deep linking, data-driven routes and morepub.dev また、機能ごとにファイルを分割する。 以下の環境です。...

View Article

Image may be NSFW.
Clik here to view.

Flutter go_router + hooks_riverpod で公式サンプル動かすチュートリアル

概要 Flutter + go_router + hooks_riverpod で、公式サンプルを機能ごとにファイル分割する。 いずれ状態変化で画面遷移したいため。 以下の環境で行う。 Flutter 2.8.1go_router 3.0.1hooks_riverpod : 1.0.3 hooks_riverpod Riverpod は Flutter の状態管理ライブラリの一つ。 グローバルで...

View Article


Image may be NSFW.
Clik here to view.

Language Learning with Youtube BETA ( LLY ) が使えなくなったので Language Reactor を使うようにした

概要 Language Learning with Youtube BETA で Youtube を日本語・英語同時字幕で見ていた。 Language Learning with Youtube BETAImprove your skills on your own, effectively and enjoyably, by watching videos in the language you...

View Article

Image may be NSFW.
Clik here to view.

[Flutter] カウンターアプリを flutter_riverpod で作るチュートリアル

概要 カウンターアプリを Riverpod で作る。 サンプルは flutter_riverpod 公式の Example を利用する。 flutter_riverpod | Flutter PackageA simple way to access state from anywhere in your application while robust and testable. pub.dev...

View Article

Image may be NSFW.
Clik here to view.

[Flutter] カウンターアプリを hooks_riverpod + StateNotifier で作るチュートリアル

概要 やりたいこと hooks_riverpod の公式 Example をコードリーディングし、機能ごとにファイル分割を行う。 題材となるプログラムは下記を参考にする。 hooks_riverpod | Flutter PackageA simple way to access state from anywhere in your application while robust and...

View Article
Browsing all 167 articles
Browse latest View live