Macのアクティビティモニターで、謎のプロセスがいる。

どうやら、「仮想マシンサービス」らしく、Podmanだった。
Dockerでも「Docker 仮想マシンサービス」となるところが、「Dockerの莉ョ諠ウ繝槭す繝ウ繧オ繝シ繝薙せ」となるケースがあるらしい。

Macのアクティビティモニターで、謎のプロセスがいる。
どうやら、「仮想マシンサービス」らしく、Podmanだった。
Dockerでも「Docker 仮想マシンサービス」となるところが、「Dockerの莉ョ諠ウ繝槭す繝ウ繧オ繝シ繝薙せ」となるケースがあるらしい。
タイトルの通りjsの日付ライブラリmomentの日付操作のパラメータが変更になっていた。
確認したのは2.29.1
"dependencies": {
"moment": "^2.29.1"
}
moment().add( 'days' , -6,).format("YYYY-MM-DD");
Deprecation warning: moment().add(period, number) is deprecated. Please use moment().add(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info.
moment().add( -6, 'days' ).format("YYYY-MM-DD");
/wp-json/contact-form-7/v1/contact-forms/{postId}/feedback
フォームの送信先はAjaxでここにアクセスしてた。
ここで作成されたカスタムエンドポイント
plugins/contact-form-7/includes/rest-api.php
register_rest_route( $namespace,
'/contact-forms/(?P<id>\d+)/feedback',
array(
array(
'methods' => WP_REST_Server::CREATABLE,
'callback' => 'wpcf7_rest_create_feedback',
'permission_callback' => '__return_true',
),
)
);
function wpcf7_rest_create_feedback( WP_REST_Request $request ) {
$url_params = $request->get_url_params();
$item = null;
if ( ! empty( $url_params['id'] ) ) {
$item = wpcf7_contact_form( $url_params['id'] );
}
if ( ! $item ) {
return new WP_Error( 'wpcf7_not_found',
__( "The requested contact form was not found.", 'contact-form-7' ),
array( 'status' => 404 )
);
}
$result = $item->submit();
$unit_tag = $request->get_param( '_wpcf7_unit_tag' );
$response = array(
'into' => '#' . wpcf7_sanitize_unit_tag( $unit_tag ),
'status' => $result['status'],
'message' => $result['message'],
'posted_data_hash' => $result['posted_data_hash'],
);
wpcf7_contact_formで取得したインスタンスのsubmitを実行してるので中身をみる
contact-form.php
public function submit( $args = '' ) {
$args = wp_parse_args( $args, array(
'skip_mail' =>
( $this->in_demo_mode()
|| $this->is_true( 'skip_mail' )
|| ! empty( $this->skip_mail ) ),
) );
if ( $this->is_true( 'subscribers_only' )
and ! current_user_can( 'wpcf7_submit', $this->id() ) ) {
$result = array(
'contact_form_id' => $this->id(),
'status' => 'error',
'message' => __(
"This contact form is available only for logged in users.",
'contact-form-7'
),
);
return $result;
}
$submission = WPCF7_Submission::get_instance( $this, array(
'skip_mail' => $args['skip_mail'],
) );
$result = array(
'contact_form_id' => $this->id(),
'status' => $submission->get_status(),
'message' => $submission->get_response(),
'demo_mode' => $this->in_demo_mode(),
);
if ( $submission->is( 'validation_failed' ) ) {
$result['invalid_fields'] = $submission->get_invalid_fields();
}
switch ( $submission->get_status() ) {
case 'init':
case 'validation_failed':
case 'acceptance_missing':
case 'spam':
$result['posted_data_hash'] = '';
break;
default:
$result['posted_data_hash'] = $submission->get_posted_data_hash();
break;
}
do_action( 'wpcf7_submit', $this, $result );
return $result;
}
ahamoにdocomoのギガホから変更しようと思ったら、「料金明細サービス」の設定状態が原因で手続きができませんでした。
「現在のご契約状態ではahamoへのプラン変更ができません。」
「料金明細サービス 明細内訳表示設定(WORLD WING) 下4桁を除き表示■料金明細サービス明細内訳表示設定(WORLD WING):「下4桁を除き表示」から「全桁表示(すべて表示)」への設定変更をお願いします」
そんな設定した覚えがなく、WORLD WINGも加入はしてるけどってレベルなので調べました。
現在のご契約状態ではahamoへのプラン変更ができません。
以下の項目をご確認いただき、各サービスの申込/廃止/設定変更等のお手続きを実施いただいた後、ahamoへのプラン変更をお申込みください。
サービスの申込/廃止/変更については、My docomo、ドコモインフォメーションセンター(局番なし151)、お近くのドコモショップにてお手続きが可能です。
※dアカウントの発行、dポイントクラブ入会、オンライン発行dポイントカード発行/登録がお済みでない方は、お手続きをお願いします。
※ahamoへのプラン変更時の「事前に必要なお手続き」について詳しくはコチラ
■料金明細サービス
明細内訳表示設定(WORLD WING):「下4桁を除き表示」から「全桁表示(すべて表示)」への設定変更をお願いします
WORLD WINGの下4桁を除き表示なんて設定したっけ?というくらい忘れてる項目でどこから変えるかもわからない。。
確かにDocomoの契約変更から見ると「WORLD WING」は契約中で料金明細の表示区分は下4桁を除き表示ってなってるけど、お手続き内容に「国際ローミングサービス( WORDL WING)を解約する」しかない。。
どこから設定変更するんだろう。
ahamoだと「WORLD WING Wi-Fi」が使えないこととローミングできる国が少ないのは知ってるけど、明細の表示とかどうでもよくない?
151のWORDLWING窓口でmydocomoを見ながら教えていただいたんですが、WORDLWINGは契約中だけど、WORDLWING料金明細サービスは未契約でした。
ちなみに下4桁を除き表示はデフォルト設定らしく、ローミング中に電話した相手の電話番号を明細にどう表示するか?の設定らしいです。
自分の場合はWORDLWING料金明細サービスは未契約なので、WORDLWINGの設定変更とかじゃなく、ahamo側の問題ということで電話を回してもらえました。
自分の場合、料金明細サービスに申し込んでいなかったので、エラーだったのですが、「明細内訳表示設定(WORLD WING):「下4桁を除き表示」から「全桁表示(すべて表示)」への設定変更をお願いします」という表示になってしまっているとのことでした。
申込はmydocomoから行えて、申し込み後すぐに適用されます。
申込後、設定を見てみると契約中となって、表示区分も全桁表示になっていました。
下4桁表示がデフォルトって言われてたけど。。未契約状態の表示のことなのかな。
これでahamoでエラーがでなくなりました。
Redashのソースコードを修正する必要がでたのでredash(v9)をdocker-composeで起動した際にbuildでエラーが発生したので修正
rsion is compatible with other requirements. This could take a while.
INFO: pip is looking at multiple versions of atsd-client to determine which version is compatible with other requirements. This could take a while.
ERROR: Cannot install -r requirements_all_ds.txt (line 12), -r requirements_all_ds.txt (line 21) and -r requirements_all_ds.txt (line 34) because these package versions have conflicting dependencies.
The conflict is caused by:
atsd-client 3.0.5 depends on python-dateutil
azure-kusto-data 0.0.35 depends on python-dateutil>=2.8.0
dql 0.5.26 depends on python-dateutil<2.7.0
To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict
ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/user_guide/#fixing-conflicting-dependencies
ERROR: Service 'server' failed to build : The command '/bin/sh -c if [ "x$skip_ds_deps" = "x" ] ; then pip install -r requirements_all_ds.txt ; else echo "Skipping pip install -r requirements_all_ds.txt" ; fi' returned a non-zero code: 1
rsion is compatible with other requirements. This could take a while.
INFO: pip is looking at multiple versions of atsd-client to determine which version is compatible with other requirements. This could take a while.
ERROR: Cannot install -r requirements_all_ds.txt (line 20) and mysqlclient==1.3.14 because these package versions have conflicting dependencies.
ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/user_guide/#fixing-conflicting-dependencies
The conflict is caused by:
The user requested mysqlclient==1.3.14
memsql 3.0.0 depends on mysqlclient==1.3.13
To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict
ERROR: Service 'server' failed to build : The command '/bin/sh -c if [ "x$skip_ds_deps" = "x" ] ; then pip install -r requirements_all_ds.txt ; else echo "Skipping pip install -r requirements_all_ds.txt" ; fi' returned a non-zero code: 1
rc211v-linough:redash-9.0.0-beta yuta_takehira$ docker-com
requirements_all_ds.txtの2箇所をコマンとアウトして再実行すれば起動できました。
memsqlとdqlです。
google-api-python-client==1.7.11
gspread==3.1.0
impyla==0.16.0
influxdb==5.2.3
mysqlclient==1.3.14
oauth2client==4.1.3
pyhive==0.6.1
pymongo[tls,srv]==3.9.0
vertica-python==0.9.5
td-client==1.0.0
pymssql==2.1.4
#dql==0.5.26
dynamo3==0.4.10
boto3>=1.10.0,<1.11.0
botocore>=1.13,<1.14.0
sasl>=0.1.3
thrift>=0.8.0
thrift_sasl>=0.1.0
cassandra-driver==3.21.0
#memsql==3.0.0
atsd_client==3.0.5
simple_salesforce==0.74.3
PyAthena>=1.5.0
pymapd==0.19.0
qds-sdk>=1.9.6
ibm-db>=2.0.9
pydruid==0.5.7
requests_aws_sign==0.1.5
snowflake-connector-python==2.1.3
phoenixdb==0.7
# certifi is needed to support MongoDB and SSL:
certifi>=2019.9.11
pydgraph==2.0.2
azure-kusto-data==0.0.35
pyexasol==0.12.0
python-rapidjson==0.8.0
pyodbc==4.0.28
LINE BOTでFlexメッセージなどをテストする必要があり、最新版のline-bot-sdkを別ディレクトリにcomposerでインストールしようとしたところエラーとなりました。
以前はさくらのレンタルサーバーでもcomposer でLINE BOT SDKがインストールできましたが、下記のエラーでLine-bot-sdkのインストールに失敗。。
Using version ^4.5 for linecorp/line-bot-sdk
./composer.json has been created
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for linecorp/line-bot-sdk ^4.5 -> satisfiable by linecorp/line-bot-sdk[4.5.0].
- linecorp/line-bot-sdk 4.5.0 requires ext-sockets * -> the requested PHP extension sockets is missing from your system.
To enable extensions, verify that they are enabled in your .ini files:
- /usr/local/php/7.4/etc/php.ini
- /usr/local/php/7.4/etc/conf.d/apcu.ini
- /usr/local/php/7.4/etc/conf.d/mcrypt.ini
- /usr/local/php/7.4/etc/conf.d/opcache.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
Installation failed, deleting ./composer.json.
エラーはext-socketsがphpで有効になっていない為で、ext-socketsはLINE SDKのcomposer.jsonを見ると最近のアップデートでrequireにext-soketsが追加されていました。
"require": {
"php": ">=5.5",
"ext-curl": "*",
"ext-json": "*",
"ext-sockets": "*"
},
ext-socketsはさくらのレンタルサーバーのphp.iniではコメントアウトされています。
自分用のphp.iniにモジュールを追加すればいいかと思いましたが、そもそもさくらレンタルサーバーのPHPのエクステンションにはsockets.soは入っていません。
cat /usr/local/php/7.4/etc/php.ini | grep socket
; Default timeout for socket based streams (seconds)
; http://php.net/default-socket-timeout
default_socket_timeout = 60
;extension=sockets
$ ll /usr/local/php/7.4/lib/php/extensions/no-debug-non-zts-20190902/
total 2348
-rw-r--r-- 1 root wheel 124476 Aug 7 09:14 apcu.so
-rw-r--r-- 1 root wheel 595997 Aug 7 09:13 imagick.so
-rw-r--r-- 1 root wheel 61009 Aug 7 09:14 mcrypt.so
-rw-r--r-- 1 root wheel 312644 Aug 7 09:13 oauth.so
-rwxr-xr-x 1 root wheel 1185945 Aug 7 09:12 opcache.so
php-configで確認するとさくらレンタルサーバーのPHP7.4.9ではSocketは指定されていないので、sockets.soを自前で準備する必要があります。
--configure-options [--prefix=/usr/local/php/7.4 --mandir=/usr/local/php/7.4/man --with-config-file-path=/usr/local/php/7.4/etc --with-config-file-scan-dir=/usr/local/php/7.4/etc/conf.d --with-apxs2=/usr/local/apache/bin/apxs --with-openssl --with-zlib --with-curl --enable-exif --enable-gd --with-jpeg --with-webp --with-freetype --with-gettext --with-gmp --with-iconv-dir=/usr/local --enable-intl --enable-mbstring --with-mysqli=mysqlnd --with-pdo-mysql=mysqlnd --with-snmp --enable-soap --with-xsl --enable-opcache --with-zip --enable-ftp --with-pear OPENSSL_CFLAGS=-I/usr/include OPENSSL_LIBS=-L/usr/lib -lssl -lcrypto]
まずは、同じバージョンのPHPのソースを落として、解凍したphpのソースディレクトリ内のext内にあるsocketsディレクトリ でビルドを行い、sockets.soを自分のphp.iniで指定します。
$ php -v
PHP 7.4.9 (cli) (built: Aug 7 2020 09:12:44) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
with Zend OPcache v7.4.9, Copyright (c), by Zend Technologies
$ wget https://github.com/php/php-src/archive/php-7.4.9.zip
解凍して
$cd ./php-src-php-7.4.9/ext/sockets/
$phpize
Configuring for:
PHP Api Version: 20190902
Zend Module Api No: 20190902
Zend Extension Api No: 320190902
$./configure --prefix=/home/○○/php_modules/
$ make
cp ./.libs/sockets.so /home/〇〇/php-src-php-7.4.9/ext/sockets/modules/sockets.so
cp ./.libs/sockets.lai /home/〇〇/php-src-php-7.4.9/ext/sockets/modules/sockets.la
出来上がった、sockets.soとsockets.laiを自分のphp.iniで指定して、aliasでphp.iniを読み込む様に変更してから、下記のコマンでインストールが成功
$ alias php='/usr/local/bin/php -c /home/〇〇/www/php.ini'
$ php ~/bin/composer.phar require linecorp/line-bot-sdk
PHP Warning: PHP Startup: mailparse: Unable to initialize module
Module compiled with module API=20170718
PHP compiled with module API=20190902
These options need to match
in Unknown on line 0
Using version ^4.5 for linecorp/line-bot-sdk
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
- Installing linecorp/line-bot-sdk (4.5.0): Downloading (100%)
linecorp/line-bot-sdk suggests installing apigen/apigen (Install with roave/better-reflection:dev-master to generate docs)
linecorp/line-bot-sdk suggests installing roave/better-reflection (Required by apigen/apigen:dev-master)
Package oscarotero/psr7-middlewares is abandoned, you should avoid using it. Use middlewares/* instead.
Writing lock file
Generating autoload files
我が家はデスクトップはiMacのみで、モニターやキーボードを準備するのが面倒なのでRaspberryPiのセットアップはいつもヘッドレスで行っています。
sshファイルとwpa_supplicant.confの設定してbonjourかarpの一覧表示でIPを調べられます。
RC211v-mbp:Downloads dp$ ping raspberrypi.local
PING raspberrypi.local (192.168.1.39): 56 data bytes
64 bytes from 192.168.1.39: icmp_seq=0 ttl=64 time=3.794 ms
64 bytes from 192.168.1.39: icmp_seq=1 ttl=64 time=3.411 ms
^C
--- raspberrypi.local ping statistics ---
2 packets transmitted, 2 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 3.411/3.603/3.794/0.192 ms
RC211v-mbp:Downloads dp$
RC211v-mbp:Downloads dp$arp -a
? (169.254.118.171) at b8:27:eb:97:d6:6d on en0 [ethernet]
? (192.168.1.1) at e4:7e:66:34:1b:58 on en0 ifscope [ethernet]
? (192.168.1.6) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.7) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.8) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.9) at 18:65:90:d0:51:5 on en0 ifscope permanent [ethernet]
? (192.168.1.10) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.11) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.12) at f0:81:73:98:aa:5b on en0 ifscope [ethernet]
? (192.168.1.13) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.14) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.15) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.16) at (incomplete) on en0 ifscope [ethernet]
? (192.168.1.22) at 7c:61:66:da:d7:41 on en0 ifscope [ethernet]
? (192.168.1.39) at b8:27:eb:97:d6:6d on en0 ifscope [ethernet]
? (192.168.1.255) at ff:ff:ff:ff:ff:ff on en0 ifscope [ethernet]
? (224.0.0.251) at 1:0:5e:0:0:fb on en0 ifscope permanent [ethernet]
? (239.255.255.250) at 1:0:5e:7f:ff:fa on en0 ifscope permanent [ethernet]
GoogleDriveは使ってないんですが
たまたまGmailのメールから添付Drive経由で開いて、削除しようと一覧を開いたらエロ画像が置かれていて、x****@gmail.comと共有になっていて、半年以上前からになっていて、Googleに削除されなかったのが救い。。
何かアプリをインストールした時なのか、わからないけどドライブへの許可をしてたみたいで、API経由でアップロードなのかシェアされていたみたい。
使わないつもりのサービスでもたまにチェックしないと、不意にアカウント停止の対象になるかもしれない。
リリースしたアプリがAndroid9でクラッシュしてしまうらしい。
手元にAndroid9(Pie)がないのでエミュレーターで確認すると、確かにMainActivityが起動できていない。
ログを見ると、android.view.InflateExceptionが発生していた。
Android8とかでは何機種試したけど、普通に動作するんだけどな。。
Process: com.doroidpanic.test, PID: 28843
android.view.InflateException: Binary XML file line #28: Binary XML file line #28: Error inflating class TextView
Caused by: android.view.InflateException: Binary XML file line #28: Error inflating class TextView
Caused by: java.lang.NumberFormatException: For input string: "bold"
「java.lang.NumberFormatException: For input string: “bold”」???
ログに出てるXMLを追ってくと、確かにTextViewに行き着いて
そのTextViewにはtextFontWeightが指定してある。
android:textFontWeight="bold"
AndroidStudioが「Attribute textFontWeight is only used in API level 28 and higher r (current min is 21)」と言ってるけど、非推奨とかじゃないしな。。
この書き方も同じエラーで落ちる。
android:textStyle="bold"
LINEのタイムランで流れてきた詐欺?サイト
スクラッチを削るってところがキラキ●ウォーカー風だなと思って見てみたら、自分も「いいね」したことになっていて、HTMLをみてみたらLINEイイネのボタンがZ-index + 透明 + 全画面という昔Facebookいいねボタンで流行った手口になっていた。
スクラッチを削ろうとしてタップしたり、会社概要を探そうとタップすると
LINEいいねを押してしまう仕様になってる。
ただ、開いたブラウザでLINEログインしていないといけないのでFacebookよりは発動条件が厳しいようです。