Aynakeya's Blog

Kill My Emotion

Intro

by ChatGPT

During my recent work, I attempted to install the Kubuntu operating system on a ThinkBook 16+. However, I encountered an intriguing issue. After successful installation, I began to experience unpredictable system crashes followed by a reboot. In this blog, I will share my troubleshooting and resolution process, hoping to help readers who encounter similar issues.

Read more »

引言

在我的一个项目中,,我需要在Fyne编写的GUI中播放视频。然而Fyne这个框架原生并不支持视频播放,所以我引入了MPV作为视频解码与播放的库。

为了将MPV的输出集成到Fyne的GUI中,我可以通过设置MPV的wid选项来控制。在Windows上,这个WID就是Windows
handle id (HWND)。 在Linux中,这个ID通常为X11的window id。

然而,Fyne同样不支持直接获取window id。为了实现这个功能,我们需要对Fyne进行一些修改,具体修改如下。

Read more »

《宇宙飞行手册》前115章简评

这本书连载于起点中文网,目前尚未完结。

阅读感受包括剧透,但不包括剧情和任务的介绍。如果还未读过这本书,建议先阅读再参考此评价。

前言

在朋友Y的推荐下阅读了这本书,朋友Y的推荐语是:“如果你觉得前三章好看,那么你一定会喜欢这本书。”

我认为这话既对,又不尽然。

Read more »

前言

说点前言,但是我又不知道说啥了。

由于最近突然喜欢在做事情的时候开个有声小说,于是我就把喜马拉雅这个软件重新下载了下来,并小冲了一个会员。

我注意到喜马拉雅这个客户端同时具有下载的功能,小小的尝试了一下,发现下载下来的文件为.xm文件格式。这个格式属于一种加密的格式,除了喜马拉雅客户端之外都不能播放。

什么,加密的?这怎么能忍。

仅限于学习交流使用,本文作者不负任何其他责任

Disclaimer: Only used for educational purpose.

Read more »

In Feb.6 2022. I miss the interview with ****(name reducted). The reason for that is that my calendar had its sheduled interview time at 12:30 instead of 11:30.The event in the calendar was automatically added using an todo list application (a sub module of FMA) written by myself, so there must be a hidden bug I didn't find.

Debugging

I first analyze the process of event synchronization. There are basically two stage, the first stage is parsing, the second stage is send request to calendar api.

I first test calendar api using an unit test I've already written. Everything works fine.

So, the problem occurs in time parsing stage.

After running another unit test, I found out there was a bug in time conversion. I forgot to change timezone value

1
2
// to unix time
currentTime.Add(time.Hour*(-7))

because In Canada, there is a daylight saving time. In winnter, it is actually -8 instead of -7!

As a result, the calculated time is one hour later than the actual time.

Fixing

1
2
// to unix time
currentTime.Add(time.Hour*delta)

Lesson Learned

Never use your own application in real shit

PrairieLearn Java Autograder Vulnerability

Aynakeya aynakeya.official@gmail.com

Abstract

This is a walkthrough of one vulnerability I found in PrairieLearn Java autograder.

The default Java autograder exists vulnerabilities that allow user to leak information and write files to the container.

These vulnerabilities allow the user to modify the result of autograder score and get 100% without writing any actual code.

Vulnerability has been fixed in commit 7871ce5

Since the vulnerability hasn't been fixed yet. Anyone who read this document should not disclose the content of the vulnerability

to public in any form until the vulnerability is fixed and deployed to production.

Read more »

从0开始的VB程序破解

上周,为了整点乐子,我打算寻找一个简单的软件来进行破解。正好某群友有一个需要破解的应用,于是这个应用就不幸的成为了我的目标。

开始之前先来介绍一下这个程序,MagicEXIF一个非常强大的图片元数据编辑器。 分为免费版,专业版,旗舰版。

安装完程序后,先来看看程序的基本信息

Read more »

Linux piping in summary

Symbol Purpose
| pipe standard out from one program to standard input of another
< redirect standard in from a file
> redirect standard out to a file, deleting its current contents
&> redirect both standard out and standard error to a file, deleting its current contents
>> redirect standard out to a file, adding to the end of tis current contents
&>> redirect both standard out and standard error to a file, adding to the end of its current contents
0%