How to unpack Safeguard 1.03? - reverse-engineering

I have an executable file ,which is about network authentication.And I want to unpack it.
When I check it with exeinfope,it shows it is writed by E language,not packed.
However when I check it with PEiD,it shows it is packed by Safeguard 1.03.
I open it with ollydbg and try to find the OEP.
I am searching for a long time on net.But no use.Please help or try to give some ideas how to achieve this.

Related

"/usr/bin/google-chrome" is not an ELF file

I am going to use ltrace for some applications like chrome but when I use it, I receive the following error message.
"/usr/bin/google-chrome" is not an ELF file
Does anybody know about the solution? I want to know what functions are exactly called by running an application.
Thanks,
Does anybody know about the solution?
file -L /usr/bin/google-chrome
/usr/bin/google-chrome: Bourne-Again shell script, ASCII text executable
This tells you that google-chrome is a shell script. If you look inside, you'll see that it eventually invokes a real ELF binary (/opt/google/chrome/chrome on my system).
I want to know what functions are exactly called by running an application.
The ltrace command will not show you that. It will only show you what external functions are getting called.

Verify a Tif with ApprovalTests

I have been asked to update a system where header information gets injected into a tif via a 3rd party console application. I don't need to worry about that bit.
The part I have been asked to look at it the merge process that generates the header information.
The current file generated by the process is assumed as correct, before I make any changes, so I want to add this as an approved result, from that I can then check that the changes I make will alter the file as expected.
I thought this would be a good opportunity to look at using ApprovalTests
The problem I have is that for what ever reason the links to the videos are considered corruptible (Possibly show me kittens jumping into boxes or something, which will stop me working, which ironically means I slow down my work done because I cannot see any help videos).
What I have been looking at is the Approvals.Verify and Approvals.VerifyFile extensions.
But what appears to be happening is confusing me.
using VerifyFile creates a received file, but the contents of the file are just a line the name of the file I have asked it to verify.
using Verify(new FileInfo("FileNameHere")) does not appear to generate the received file that I need to flag as approved, but the test does return saying that it cannot find the approved tif file.
I am probably using VerifyFile completely wrong and might be looking at using Verify wrong as well.
useful info?
Might be useful to know, that as this is a legacy application, running as a windows service, I have wrapped the service in a harness that allows me to call the routines, so the files are physically being written elsewhere on the machine outside of my control (well there is a config, but the return of the service I call generates a file in a fixed location if it is successful). I have tried copying that into the Unit Test project, but that doesn't appear to help.
Verify(File) and VerifyFile(string) are both meant to verify an existing file. As such they merely setting the received file to the file you pass in. You will still need to move/approval/create the approved file.
Here is the pseudo code and process.
[UseReporter(typeof(DiffReporter), typeof(ClipboardReporter)]
public void TestTiff()
{
string tif = YourProcessToCreateTifFile();
Approvals.VerifyFile(tif);
}
[Note: if you don't have an image diff installed, like TortoiseDiff, you might want to use the FileLauncherReporter]
Run this, once you get the result, move the file over by pasting your clipboard into a cmd window.
It will move the temporary tif to your test directory with the name ClassName.TestTiff.approved.tif
After that the test should pass until something changes.
Happy Testing!

Close a single tab in Chrome using Batch command

I'm relatively new to batch commands and have been learning steadily. My problem is like this:
I've understood how to kill processes using batch commands using many different methods. However, I've been unable to figure out how to close a single tab in, preferably, chrome.
Any thoughts would be greatly appreciated!
Thanks!
So, I suppose I should state my exact problem.
I'm using notepad++ as my LaTeX compiler and sending the final pdf to chrome. The reason: I usually have ~20 tabs open related to the project I'm working on and it just makes my work much easier to split my screen between notepad++ and chrome.
My current batch file compiles the LaTeX code and sends the compiled document to chrome as a new tab. For obvious reasons, i don't want to close a tab each time I compile, so I thought that closing the current tab at the same time during compiling would solve my problem. But, I just can't find a way to get my batch file to only close the tab with my compiled pdf.
Thanks in advance!
check all running chrome instances/tabs with :
wmic process where "caption='chrome.exe'" get
and see processes properties.Probably the best indicator that you can rely on in this case is CreationDate (other properties are basically the same for all chrome instances) - it always comes in format YYYYMMDDHHmmss.ms and is easy for string comparison.But you'll have to know the time when it was started.

In monodevelop how can I clear out the Task list?

My task list pad is filled with old //Todo comment tasks that have been parsed out of the code. Unfortunately the files they refer to have long since gone and the tasks are hanging around like zombies. Deleting each task simply throws an error that the file is missing. How can I manually force a complete cleanout of the tasks list so it can reparse? I had a quick look at the source code for this part of MD but I didn't see anything obvious.
I'd suggest you file a bug.
However, for a quick workaround, try deleting the code completion database caches. On Mac you can find them in ~/Library/Caches/MonoDevelop-3.0/DerivedData, and on Windows they're in AppData\Local\MonoDevelop-3.0\Cache\DerivedData.

How to get a list of files with errors in PhpStorm

In PhpStorm I get a read mark on the upper right side of the code window if there's a PHP bug in the file. That's great. What I like to have is a list of all files which have this read mark.
Any ideas?
To get the list of all files with errors and warnings use Code | Inspect Code. It's possible to specify what inspection profile to use, which directories to scan. Custom Scope provides a flexible way to include/exclude certain directories or files from the inspection results.
Slightly off-topic, but may be helpful. If you need to jump through all the errors in a file (for example, CSS file), open up the file and and hit the F2 button on the keyboard. Repeat it to cycle through all the errors. To navigate back to the previous error, hit Shift + F2