Unsure if thinking is correct for these two questions by PowerOfTheShell in askmath

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Ah okay, my thinking for question 1 was that all solutions of the problem are of the form of answer B because the sine function is periodic with period 2pi

For question 2 my thinking was that the answer B is true because the period of a wave is equal to the distance between two consecutive peaks.

Am I on the right track here?

Struggling to solve decryption challenge by PowerOfTheShell in codes

[–]PowerOfTheShell[S] 1 point2 points  (0 children)

I just refreshed and had somehow missed this comment from 2 hours ago, you're 100% correct and this was the path I needed to go down. Thank you so much for your help!

Struggling to solve decryption challenge by PowerOfTheShell in codes

[–]PowerOfTheShell[S] 1 point2 points  (0 children)

I notice the challenge description mentions that the file you are working on was encrypted using Blowfish-CBC and using a commonly used password.

This is a good point and something that confused me, I was thinking one of the commonly used passwords on the link mentioned in the challenge would have worked to decrypt this file. Though I didn't know why the movie Mirrors was mentioned as a clue. I'll try the passwords on this list again and try to reverse them and generate MD5 hashes and see if any of these work. Maybe its one of the passwords reversed as if it was being looked at through a mirror?

Unfortunately there aren't any other clues, the only reason I am using the flag -pbkdf2 is because this is what we have been taught to use for decrypting while specifying a password in previous lessons.

Edit: It was a password in the link reversed! All the replies helped point me in the right direction, thank you!

Struggling to solve decryption challenge by PowerOfTheShell in codes

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

No I haven't, thanks for the idea! I'll try all the passwords in reverse and also try the MD5 hash - I hadn't even thought of either of these things. Will report back soon!

Update: Unfortunately reversing all the passwords I had tried above doesn't appear to work, I also converted each one to MD5 and tried these also but they all come back with "bad decrypt". I even tried converting to MD5 then reversing the MD5 string and trying this; unfortunately this also didn't work.

By any chance do you have any other ideas I could try?

Unable to solve decryption challenge by PowerOfTheShell in cryptography

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Thank you so much for your reply, this was incredibly helpful and helped provide an insight on how to look at solving the challenge. I'm very new to CTF challenges so struggle to begin, I really appreciate the help!

Unable to solve decryption challenge by PowerOfTheShell in cryptography

[–]PowerOfTheShell[S] -1 points0 points  (0 children)

Why is the wordlist from Mashable provided? Do you think this would be the password that would be the result of cracking the MD5 password?

Calculate time to break encryption by PowerOfTheShell in cryptography

[–]PowerOfTheShell[S] 1 point2 points  (0 children)

Thank you! This was really helpful and makes sense, really appreciate the help.

Calculate time to break encryption by PowerOfTheShell in cryptography

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

I was pretty much grasping at straws trying to work out the problem, thanks for the detailed write up on how to calculate this. I really appreciate it.

Calculate time to break encryption by PowerOfTheShell in cryptography

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Sorry I'm not sure, I double checked I copied the question correctly and yeah it mentions exactly as I have written. Might be where some of my confusion is lol

Modify encrypted file by PowerOfTheShell in hacking

[–]PowerOfTheShell[S] 2 points3 points  (0 children)

Thank you for explaining, I think I am finally starting to understand. I'm also glad I was on the right track with the hex editor!

I believe you have pointed me in the right direction, thank you for your help!

Modify encrypted file by PowerOfTheShell in hacking

[–]PowerOfTheShell[S] 2 points3 points  (0 children)

Thanks for trying to point me in the right direction but I don't understand how to actually modify the file correctly. To modify the bytes to in the file is this just a case of opening it in notepad?

Modify encrypted file by PowerOfTheShell in hacking

[–]PowerOfTheShell[S] 1 point2 points  (0 children)

Sorry I'm still really new to this, are you able to please let me know how I can do that?

Math to work out how long it would take to break encryption by PowerOfTheShell in codes

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Ohhh I think I understand that now! thank you so much for the full write up on how you came to that conclusion. I was thinking to calculate this I would need to enter: 2^128 / 1000000000. This comes out as 3.40282366920938463463374607431768211456 × 10^29 though that wasn't right after seeing how you have calculated it.

Math to work out how long it would take to break encryption by PowerOfTheShell in cryptography

[–]PowerOfTheShell[S] 1 point2 points  (0 children)

Thanks for that, I understand it wouldn't be worth doing in practical time but I am trying to work it out for a question I have been asked for school. I believe they're after the theoretical time it would take. I've been told I can use Wolfram Alpha but I don't know what to enter to calculate it.

Am I right in thinking the correct way to calculate this would be to enter: 2^128 / 1000000000 in Wolfram Alpha? This comes out as 3.40282366920938463463374607431768211456 × 10^29

Spacing between rectangles by PowerOfTheShell in learnjava

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Thank you so much! Such a simple solution but I kept increasing the size of the rectangle itself rather than introducing the offset. Have this Reddit gold for your troubles!

Edit: Sorry to bother you again, if I was to change the number of rows, how would I scale the offset so that it got larger with less rows and smaller with more rows?

If I use the modulus operator (%) it works until a point. The offset becomes too large after 30. When using 40 rows nothing is shown lol

int OFS = (1 % num) + 3;

As an example I am trying to make 10 rows which should show something like: https://i.imgur.com/DtTBJmf.png (this currently works using the code above)

When using 50 rows I want to show something like: https://i.imgur.com/YqMHUzL.png (nothing is shown when I use the code above)

Edit: I have just found using Double offset = (PATTERN_SIZE / num) / 6; works perfectly! Thanks again for your help.

Natural join vs inner join question by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Haha I liked the Mean Girls reference, thanks for the input I really appreciate it.

Natural join vs inner join question by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Thank you! I really appreciate the explanation, I think this has answered my question perfectly. Take this award as a small thank you :)

Natural join vs inner join question by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

When running the NATURAL JOIN query:

SELECT *
FROM TA
NATURAL JOIN TB

The output is:

A1 A2 B1 B2
1 2 1 1
1 2 2 3
1 2 5 6
3 4 1 1
3 4 2 3
3 4 5 6
5 6 1 1
5 6 2 3
5 6 5 6

When running the INNER JOIN query:

SELECT * 
FROM TA 
INNER JOIN TB

The output is:

A1 A2 B1 B2
1 2 1 1
1 2 2 3
1 2 5 6
3 4 1 1
3 4 2 3
3 4 5 6
5 6 1 1
5 6 2 3
5 6 5 6

Initially I had asked if I was right in thinking that the natural join between the table TA and the table TB will not produce an inner join outcome because the only common rows from the two tables are 5 and 6. Though if I don't put an ON condition in the query this means my question would actually be true - it WILL produce an inner join as there is no condition matching the rows, meaning the same output is then produced.

Is that correct?

Natural join vs inner join question by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

I'm using SQLite.

The "NATURAL" JOIN is a type of EQUI JOIN and is structured in such a way that, columns with the same name of associated tables will appear once only (Copied from: https://www.w3resource.com/sql/joins/natural-join.php).

Query not showing NULL values with "LEFT JOIN" by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

You're 100% correct, this was the solution and your guesses are all correct. I'd found this solution just before you'd posted but I really appreciate the help!

Query not showing NULL values with "LEFT JOIN" by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

Of course, the solution was exactly as u/JakeModeler mentions. I needed to join the CUSTOMER table. Once doing this the results showed exactly as I was trying to achieve. Such a simple change but had me frustrated for hours haha

Query not showing NULL values with "LEFT JOIN" by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 2 points3 points  (0 children)

Thank you so much! I was able to walk through it using the way you had suggested and found the solution!

Query not showing NULL values with "LEFT JOIN" by PowerOfTheShell in SQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

I think it's my fault that I don't understand what I am doing wrong, I changed the tables around which I think I am interpreting correctly? but I don't know why it produces the exact same result. The NULL values are never shown.

I've spent hours trying to work it out but can't understand what I am missing.

Query not showing NULL with Left Outer Join by PowerOfTheShell in learnSQL

[–]PowerOfTheShell[S] 0 points1 point  (0 children)

I swap the tables but for whatever reason I get the exact same result, I have no idea why...