This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ykman piv keys generate -a RSA2048 --pin-policy=NEVER --touch-policy=ALWAYS 9a public.pem | |
| ykman piv certificates generate --subject "CN=SSH key" --valid-days 3650 9a public.pem | |
| # add lib to ssh agend | |
| ssh-add -s /usr/lib/x86_64-linux-gnu/libykcs11.so | |
| # convert key for server | |
| ssh-keygen -i -m PKCS8 -f public.pem |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int save_frame_as_jpeg(AVCodecContext *pCodecCtx, AVFrame *pFrame, int FrameNo) { | |
| AVCodec *jpegCodec = avcodec_find_encoder(AV_CODEC_ID_JPEG2000); | |
| if (!jpegCodec) { | |
| return -1; | |
| } | |
| AVCodecContext *jpegContext = avcodec_alloc_context3(jpegCodec); | |
| if (!jpegContext) { | |
| return -1; | |
| } |